docrev 0.9.13 → 0.9.15

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.
Files changed (126) hide show
  1. package/.claude/settings.local.json +9 -9
  2. package/.gitattributes +1 -1
  3. package/CHANGELOG.md +149 -149
  4. package/PLAN-tables-and-postprocess.md +850 -850
  5. package/README.md +411 -391
  6. package/bin/rev.js +11 -11
  7. package/bin/rev.ts +145 -145
  8. package/completions/rev.bash +127 -127
  9. package/completions/rev.ps1 +210 -210
  10. package/completions/rev.zsh +207 -207
  11. package/dev_notes/stress2/build_adversarial.ts +186 -186
  12. package/dev_notes/stress2/drift_matcher.ts +62 -62
  13. package/dev_notes/stress2/probe_anchors.ts +35 -35
  14. package/dev_notes/stress2/project/discussion.before.md +3 -3
  15. package/dev_notes/stress2/project/discussion.md +3 -3
  16. package/dev_notes/stress2/project/methods.before.md +20 -20
  17. package/dev_notes/stress2/project/methods.md +20 -20
  18. package/dev_notes/stress2/project/rev.yaml +5 -5
  19. package/dev_notes/stress2/project/sections.yaml +4 -4
  20. package/dev_notes/stress2/sections.yaml +5 -5
  21. package/dev_notes/stress2/trace_placement.ts +50 -50
  22. package/dev_notes/stresstest_boundaries.ts +27 -27
  23. package/dev_notes/stresstest_drift_apply.ts +43 -43
  24. package/dev_notes/stresstest_drift_compare.ts +43 -43
  25. package/dev_notes/stresstest_drift_v2.ts +54 -54
  26. package/dev_notes/stresstest_inspect.ts +54 -54
  27. package/dev_notes/stresstest_pstyle.ts +55 -55
  28. package/dev_notes/stresstest_section_debug.ts +23 -23
  29. package/dev_notes/stresstest_split.ts +70 -70
  30. package/dev_notes/stresstest_trace.ts +19 -19
  31. package/dev_notes/stresstest_verify_no_overwrite.ts +40 -40
  32. package/dist/lib/build.d.ts +38 -1
  33. package/dist/lib/build.d.ts.map +1 -1
  34. package/dist/lib/build.js +68 -30
  35. package/dist/lib/build.js.map +1 -1
  36. package/dist/lib/commands/build.d.ts.map +1 -1
  37. package/dist/lib/commands/build.js +38 -5
  38. package/dist/lib/commands/build.js.map +1 -1
  39. package/dist/lib/commands/utilities.js +164 -164
  40. package/dist/lib/commands/word-tools.js +8 -8
  41. package/dist/lib/grammar.js +3 -3
  42. package/dist/lib/pdf-comments.js +44 -44
  43. package/dist/lib/plugins.js +57 -57
  44. package/dist/lib/pptx-themes.js +115 -115
  45. package/dist/lib/spelling.js +2 -2
  46. package/dist/lib/templates.js +387 -387
  47. package/dist/lib/themes.js +51 -51
  48. package/eslint.config.js +27 -27
  49. package/lib/anchor-match.ts +276 -276
  50. package/lib/annotations.ts +644 -644
  51. package/lib/build.ts +1300 -1251
  52. package/lib/citations.ts +160 -160
  53. package/lib/commands/build.ts +833 -801
  54. package/lib/commands/citations.ts +515 -515
  55. package/lib/commands/comments.ts +1050 -1050
  56. package/lib/commands/context.ts +174 -174
  57. package/lib/commands/core.ts +309 -309
  58. package/lib/commands/doi.ts +435 -435
  59. package/lib/commands/file-ops.ts +372 -372
  60. package/lib/commands/history.ts +320 -320
  61. package/lib/commands/index.ts +87 -87
  62. package/lib/commands/init.ts +259 -259
  63. package/lib/commands/merge-resolve.ts +378 -378
  64. package/lib/commands/preview.ts +178 -178
  65. package/lib/commands/project-info.ts +244 -244
  66. package/lib/commands/quality.ts +517 -517
  67. package/lib/commands/response.ts +454 -454
  68. package/lib/commands/section-boundaries.ts +82 -82
  69. package/lib/commands/sections.ts +451 -451
  70. package/lib/commands/sync.ts +706 -706
  71. package/lib/commands/text-ops.ts +449 -449
  72. package/lib/commands/utilities.ts +448 -448
  73. package/lib/commands/verify-anchors.ts +272 -272
  74. package/lib/commands/word-tools.ts +340 -340
  75. package/lib/comment-realign.ts +517 -517
  76. package/lib/config.ts +84 -84
  77. package/lib/crossref.ts +781 -781
  78. package/lib/csl.ts +191 -191
  79. package/lib/dependencies.ts +98 -98
  80. package/lib/diff-engine.ts +465 -465
  81. package/lib/doi-cache.ts +115 -115
  82. package/lib/doi.ts +897 -897
  83. package/lib/equations.ts +506 -506
  84. package/lib/errors.ts +346 -346
  85. package/lib/format.ts +541 -541
  86. package/lib/git.ts +326 -326
  87. package/lib/grammar.ts +303 -303
  88. package/lib/image-registry.ts +180 -180
  89. package/lib/import.ts +911 -911
  90. package/lib/journals.ts +543 -543
  91. package/lib/merge.ts +633 -633
  92. package/lib/orcid.ts +144 -144
  93. package/lib/pdf-comments.ts +263 -263
  94. package/lib/pdf-import.ts +524 -524
  95. package/lib/plugins.ts +362 -362
  96. package/lib/postprocess.ts +188 -188
  97. package/lib/pptx-color-filter.lua +37 -37
  98. package/lib/pptx-template.ts +469 -469
  99. package/lib/pptx-themes.ts +483 -483
  100. package/lib/protect-restore.ts +520 -520
  101. package/lib/rate-limiter.ts +94 -94
  102. package/lib/response.ts +197 -197
  103. package/lib/restore-references.ts +240 -240
  104. package/lib/review.ts +327 -327
  105. package/lib/schema.ts +417 -417
  106. package/lib/scientific-words.ts +73 -73
  107. package/lib/sections.ts +335 -335
  108. package/lib/slides.ts +756 -756
  109. package/lib/spelling.ts +334 -334
  110. package/lib/templates.ts +526 -526
  111. package/lib/themes.ts +742 -742
  112. package/lib/trackchanges.ts +247 -247
  113. package/lib/tui.ts +450 -450
  114. package/lib/types.ts +550 -550
  115. package/lib/undo.ts +250 -250
  116. package/lib/utils.ts +69 -69
  117. package/lib/variables.ts +179 -179
  118. package/lib/word-extraction.ts +806 -806
  119. package/lib/word.ts +643 -643
  120. package/lib/wordcomments.ts +817 -817
  121. package/package.json +137 -137
  122. package/scripts/postbuild.js +28 -28
  123. package/skill/REFERENCE.md +473 -431
  124. package/skill/SKILL.md +274 -258
  125. package/tsconfig.json +26 -26
  126. package/types/index.d.ts +525 -525
package/lib/themes.ts CHANGED
@@ -1,742 +1,742 @@
1
- /**
2
- * Slide Themes for Beamer and PPTX
3
- *
4
- * 20 professionally designed themes based on modern design principles:
5
- * - Bold, confident typography (2025-2026 trend)
6
- * - Curated color palettes (monochrome, earth tones, neo-mint, dark mode)
7
- * - Clean sans-serif fonts for readability
8
- * - Consistent visual hierarchy
9
- *
10
- * Each theme includes:
11
- * - Primary, secondary, accent colors
12
- * - Background and text colors
13
- * - Font recommendations
14
- * - Beamer configuration
15
- */
16
-
17
- /**
18
- * Theme colors
19
- */
20
- interface ThemeColors {
21
- primary: string;
22
- secondary: string;
23
- accent: string;
24
- background: string;
25
- backgroundDark: string;
26
- text: string;
27
- textLight: string;
28
- }
29
-
30
- /**
31
- * Theme fonts
32
- */
33
- interface ThemeFonts {
34
- heading: string;
35
- body: string;
36
- mono: string;
37
- }
38
-
39
- /**
40
- * Beamer settings
41
- */
42
- interface BeamerSettings {
43
- theme: string;
44
- colortheme: string | null;
45
- fonttheme: string | null;
46
- }
47
-
48
- /**
49
- * Complete theme definition
50
- */
51
- interface Theme {
52
- name: string;
53
- displayName: string;
54
- description: string;
55
- colors: ThemeColors;
56
- fonts: ThemeFonts;
57
- beamer: BeamerSettings;
58
- }
59
-
60
- /**
61
- * RGB color values
62
- */
63
- interface RGB {
64
- r: number;
65
- g: number;
66
- b: number;
67
- }
68
-
69
- export const THEMES: Record<string, Theme> = {
70
- // ============================================
71
- // MINIMAL & PROFESSIONAL (1-5)
72
- // ============================================
73
-
74
- metropolis: {
75
- name: 'metropolis',
76
- displayName: 'Metropolis',
77
- description: 'Clean, modern minimal theme inspired by the popular Beamer theme',
78
- colors: {
79
- primary: '#23373B', // Dark teal-gray
80
- secondary: '#EB811B', // Orange accent
81
- accent: '#14B03D', // Green
82
- background: '#FAFAFA', // Off-white
83
- backgroundDark: '#23373B',
84
- text: '#23373B',
85
- textLight: '#FAFAFA',
86
- },
87
- fonts: {
88
- heading: 'Fira Sans',
89
- body: 'Fira Sans',
90
- mono: 'Fira Mono',
91
- },
92
- beamer: {
93
- theme: 'metropolis',
94
- colortheme: null,
95
- fonttheme: null,
96
- },
97
- },
98
-
99
- nordic: {
100
- name: 'nordic',
101
- displayName: 'Nordic',
102
- description: 'Scandinavian-inspired minimal design with soft contrasts',
103
- colors: {
104
- primary: '#2E3440', // Polar Night
105
- secondary: '#5E81AC', // Frost blue
106
- accent: '#88C0D0', // Aurora cyan
107
- background: '#ECEFF4', // Snow
108
- backgroundDark: '#2E3440',
109
- text: '#2E3440',
110
- textLight: '#ECEFF4',
111
- },
112
- fonts: {
113
- heading: 'Inter',
114
- body: 'Inter',
115
- mono: 'JetBrains Mono',
116
- },
117
- beamer: {
118
- theme: 'default',
119
- colortheme: 'dove',
120
- fonttheme: null,
121
- },
122
- },
123
-
124
- slate: {
125
- name: 'slate',
126
- displayName: 'Slate',
127
- description: 'Professional gray tones with subtle blue accent',
128
- colors: {
129
- primary: '#334155', // Slate 700
130
- secondary: '#64748B', // Slate 500
131
- accent: '#3B82F6', // Blue 500
132
- background: '#F8FAFC', // Slate 50
133
- backgroundDark: '#1E293B',
134
- text: '#1E293B',
135
- textLight: '#F1F5F9',
136
- },
137
- fonts: {
138
- heading: 'IBM Plex Sans',
139
- body: 'IBM Plex Sans',
140
- mono: 'IBM Plex Mono',
141
- },
142
- beamer: {
143
- theme: 'default',
144
- colortheme: 'dove',
145
- fonttheme: null,
146
- },
147
- },
148
-
149
- paper: {
150
- name: 'paper',
151
- displayName: 'Paper',
152
- description: 'Warm, academic feel with sepia undertones',
153
- colors: {
154
- primary: '#44403C', // Stone 700
155
- secondary: '#78716C', // Stone 500
156
- accent: '#B45309', // Amber 700
157
- background: '#FAFAF9', // Stone 50
158
- backgroundDark: '#292524',
159
- text: '#1C1917',
160
- textLight: '#FAFAF9',
161
- },
162
- fonts: {
163
- heading: 'Source Sans Pro',
164
- body: 'Source Serif Pro',
165
- mono: 'Source Code Pro',
166
- },
167
- beamer: {
168
- theme: 'default',
169
- colortheme: 'seagull',
170
- fonttheme: null,
171
- },
172
- },
173
-
174
- mono: {
175
- name: 'mono',
176
- displayName: 'Mono',
177
- description: 'Pure black and white for maximum contrast',
178
- colors: {
179
- primary: '#000000',
180
- secondary: '#404040',
181
- accent: '#000000',
182
- background: '#FFFFFF',
183
- backgroundDark: '#000000',
184
- text: '#000000',
185
- textLight: '#FFFFFF',
186
- },
187
- fonts: {
188
- heading: 'Helvetica Neue',
189
- body: 'Helvetica Neue',
190
- mono: 'Menlo',
191
- },
192
- beamer: {
193
- theme: 'default',
194
- colortheme: 'dove',
195
- fonttheme: null,
196
- },
197
- },
198
-
199
- // ============================================
200
- // BOLD & MODERN (6-10)
201
- // ============================================
202
-
203
- electric: {
204
- name: 'electric',
205
- displayName: 'Electric',
206
- description: 'Bold electric blue monochrome for high-impact presentations',
207
- colors: {
208
- primary: '#2563EB', // Blue 600
209
- secondary: '#3B82F6', // Blue 500
210
- accent: '#60A5FA', // Blue 400
211
- background: '#EFF6FF', // Blue 50
212
- backgroundDark: '#1E3A8A',
213
- text: '#1E3A8A',
214
- textLight: '#EFF6FF',
215
- },
216
- fonts: {
217
- heading: 'Montserrat',
218
- body: 'Open Sans',
219
- mono: 'Fira Code',
220
- },
221
- beamer: {
222
- theme: 'default',
223
- colortheme: 'whale',
224
- fonttheme: null,
225
- },
226
- },
227
-
228
- crimson: {
229
- name: 'crimson',
230
- displayName: 'Crimson',
231
- description: 'Deep red monochrome for bold, confident statements',
232
- colors: {
233
- primary: '#DC2626', // Red 600
234
- secondary: '#B91C1C', // Red 700
235
- accent: '#F87171', // Red 400
236
- background: '#FEF2F2', // Red 50
237
- backgroundDark: '#7F1D1D',
238
- text: '#7F1D1D',
239
- textLight: '#FEF2F2',
240
- },
241
- fonts: {
242
- heading: 'Raleway',
243
- body: 'Lato',
244
- mono: 'Roboto Mono',
245
- },
246
- beamer: {
247
- theme: 'default',
248
- colortheme: 'crane',
249
- fonttheme: null,
250
- },
251
- },
252
-
253
- emerald: {
254
- name: 'emerald',
255
- displayName: 'Emerald',
256
- description: 'Rich green for environmental or growth-focused topics',
257
- colors: {
258
- primary: '#059669', // Emerald 600
259
- secondary: '#10B981', // Emerald 500
260
- accent: '#34D399', // Emerald 400
261
- background: '#ECFDF5', // Emerald 50
262
- backgroundDark: '#064E3B',
263
- text: '#064E3B',
264
- textLight: '#ECFDF5',
265
- },
266
- fonts: {
267
- heading: 'Poppins',
268
- body: 'Nunito',
269
- mono: 'Inconsolata',
270
- },
271
- beamer: {
272
- theme: 'default',
273
- colortheme: 'spruce',
274
- fonttheme: null,
275
- },
276
- },
277
-
278
- violet: {
279
- name: 'violet',
280
- displayName: 'Violet',
281
- description: 'Deep purple for creative and innovative presentations',
282
- colors: {
283
- primary: '#7C3AED', // Violet 600
284
- secondary: '#8B5CF6', // Violet 500
285
- accent: '#A78BFA', // Violet 400
286
- background: '#F5F3FF', // Violet 50
287
- backgroundDark: '#4C1D95',
288
- text: '#4C1D95',
289
- textLight: '#F5F3FF',
290
- },
291
- fonts: {
292
- heading: 'Space Grotesk',
293
- body: 'DM Sans',
294
- mono: 'JetBrains Mono',
295
- },
296
- beamer: {
297
- theme: 'default',
298
- colortheme: 'orchid',
299
- fonttheme: null,
300
- },
301
- },
302
-
303
- amber: {
304
- name: 'amber',
305
- displayName: 'Amber',
306
- description: 'Warm golden tones for engaging, energetic presentations',
307
- colors: {
308
- primary: '#D97706', // Amber 600
309
- secondary: '#F59E0B', // Amber 500
310
- accent: '#FBBF24', // Amber 400
311
- background: '#FFFBEB', // Amber 50
312
- backgroundDark: '#78350F',
313
- text: '#78350F',
314
- textLight: '#FFFBEB',
315
- },
316
- fonts: {
317
- heading: 'Outfit',
318
- body: 'Work Sans',
319
- mono: 'Source Code Pro',
320
- },
321
- beamer: {
322
- theme: 'default',
323
- colortheme: 'beaver',
324
- fonttheme: null,
325
- },
326
- },
327
-
328
- // ============================================
329
- // DARK MODE (11-14)
330
- // ============================================
331
-
332
- midnight: {
333
- name: 'midnight',
334
- displayName: 'Midnight',
335
- description: 'Deep dark mode with blue accents',
336
- colors: {
337
- primary: '#60A5FA', // Blue 400
338
- secondary: '#93C5FD', // Blue 300
339
- accent: '#3B82F6', // Blue 500
340
- background: '#0F172A', // Slate 900
341
- backgroundDark: '#020617',
342
- text: '#E2E8F0',
343
- textLight: '#F1F5F9',
344
- },
345
- fonts: {
346
- heading: 'Inter',
347
- body: 'Inter',
348
- mono: 'Fira Code',
349
- },
350
- beamer: {
351
- theme: 'default',
352
- colortheme: 'owl',
353
- fonttheme: null,
354
- },
355
- },
356
-
357
- obsidian: {
358
- name: 'obsidian',
359
- displayName: 'Obsidian',
360
- description: 'Pure dark mode with subtle purple glow',
361
- colors: {
362
- primary: '#A78BFA', // Violet 400
363
- secondary: '#C4B5FD', // Violet 300
364
- accent: '#8B5CF6', // Violet 500
365
- background: '#18181B', // Zinc 900
366
- backgroundDark: '#09090B',
367
- text: '#E4E4E7',
368
- textLight: '#FAFAFA',
369
- },
370
- fonts: {
371
- heading: 'Manrope',
372
- body: 'Manrope',
373
- mono: 'JetBrains Mono',
374
- },
375
- beamer: {
376
- theme: 'default',
377
- colortheme: 'owl',
378
- fonttheme: null,
379
- },
380
- },
381
-
382
- carbon: {
383
- name: 'carbon',
384
- displayName: 'Carbon',
385
- description: 'Tech-forward dark theme with green terminal accent',
386
- colors: {
387
- primary: '#4ADE80', // Green 400
388
- secondary: '#86EFAC', // Green 300
389
- accent: '#22C55E', // Green 500
390
- background: '#171717', // Neutral 900
391
- backgroundDark: '#0A0A0A',
392
- text: '#E5E5E5',
393
- textLight: '#FAFAFA',
394
- },
395
- fonts: {
396
- heading: 'Roboto',
397
- body: 'Roboto',
398
- mono: 'Fira Mono',
399
- },
400
- beamer: {
401
- theme: 'default',
402
- colortheme: 'owl',
403
- fonttheme: null,
404
- },
405
- },
406
-
407
- noir: {
408
- name: 'noir',
409
- displayName: 'Noir',
410
- description: 'Elegant dark mode with warm amber highlights',
411
- colors: {
412
- primary: '#FBBF24', // Amber 400
413
- secondary: '#FCD34D', // Amber 300
414
- accent: '#F59E0B', // Amber 500
415
- background: '#1C1917', // Stone 900
416
- backgroundDark: '#0C0A09',
417
- text: '#E7E5E4',
418
- textLight: '#FAFAF9',
419
- },
420
- fonts: {
421
- heading: 'Playfair Display',
422
- body: 'Lato',
423
- mono: 'IBM Plex Mono',
424
- },
425
- beamer: {
426
- theme: 'default',
427
- colortheme: 'owl',
428
- fonttheme: null,
429
- },
430
- },
431
-
432
- // ============================================
433
- // EARTH & NATURE (15-17)
434
- // ============================================
435
-
436
- forest: {
437
- name: 'forest',
438
- displayName: 'Forest',
439
- description: 'Deep greens and earthy browns for natural topics',
440
- colors: {
441
- primary: '#166534', // Green 800
442
- secondary: '#15803D', // Green 700
443
- accent: '#A3E635', // Lime 400
444
- background: '#F0FDF4', // Green 50
445
- backgroundDark: '#14532D',
446
- text: '#14532D',
447
- textLight: '#F0FDF4',
448
- },
449
- fonts: {
450
- heading: 'Josefin Sans',
451
- body: 'Merriweather Sans',
452
- mono: 'Inconsolata',
453
- },
454
- beamer: {
455
- theme: 'default',
456
- colortheme: 'spruce',
457
- fonttheme: null,
458
- },
459
- },
460
-
461
- terracotta: {
462
- name: 'terracotta',
463
- displayName: 'Terracotta',
464
- description: 'Warm earth tones with Mediterranean warmth',
465
- colors: {
466
- primary: '#C2410C', // Orange 700
467
- secondary: '#EA580C', // Orange 600
468
- accent: '#FDBA74', // Orange 300
469
- background: '#FFF7ED', // Orange 50
470
- backgroundDark: '#7C2D12',
471
- text: '#7C2D12',
472
- textLight: '#FFF7ED',
473
- },
474
- fonts: {
475
- heading: 'Cormorant Garamond',
476
- body: 'Mulish',
477
- mono: 'Cousine',
478
- },
479
- beamer: {
480
- theme: 'default',
481
- colortheme: 'beaver',
482
- fonttheme: null,
483
- },
484
- },
485
-
486
- ocean: {
487
- name: 'ocean',
488
- displayName: 'Ocean',
489
- description: 'Deep teal and aqua for marine and water themes',
490
- colors: {
491
- primary: '#0D9488', // Teal 600
492
- secondary: '#14B8A6', // Teal 500
493
- accent: '#5EEAD4', // Teal 300
494
- background: '#F0FDFA', // Teal 50
495
- backgroundDark: '#134E4A',
496
- text: '#134E4A',
497
- textLight: '#F0FDFA',
498
- },
499
- fonts: {
500
- heading: 'Quicksand',
501
- body: 'Nunito Sans',
502
- mono: 'Hack',
503
- },
504
- beamer: {
505
- theme: 'default',
506
- colortheme: 'seahorse',
507
- fonttheme: null,
508
- },
509
- },
510
-
511
- // ============================================
512
- // CONTEMPORARY & TRENDY (18-20)
513
- // ============================================
514
-
515
- neomint: {
516
- name: 'neomint',
517
- displayName: 'Neo Mint',
518
- description: '2026 trend: soft futuristic mint with pastel accents',
519
- colors: {
520
- primary: '#10B981', // Emerald 500
521
- secondary: '#6EE7B7', // Emerald 300
522
- accent: '#F472B6', // Pink 400
523
- background: '#F0FDF4', // Green 50
524
- backgroundDark: '#064E3B',
525
- text: '#064E3B',
526
- textLight: '#ECFDF5',
527
- },
528
- fonts: {
529
- heading: 'Plus Jakarta Sans',
530
- body: 'Plus Jakarta Sans',
531
- mono: 'Space Mono',
532
- },
533
- beamer: {
534
- theme: 'default',
535
- colortheme: 'default',
536
- fonttheme: null,
537
- },
538
- },
539
-
540
- gradient: {
541
- name: 'gradient',
542
- displayName: 'Gradient',
543
- description: 'Modern gradient-inspired with pink to purple flow',
544
- colors: {
545
- primary: '#EC4899', // Pink 500
546
- secondary: '#8B5CF6', // Violet 500
547
- accent: '#06B6D4', // Cyan 500
548
- background: '#FDF4FF', // Fuchsia 50
549
- backgroundDark: '#701A75',
550
- text: '#701A75',
551
- textLight: '#FDF4FF',
552
- },
553
- fonts: {
554
- heading: 'Sora',
555
- body: 'Outfit',
556
- mono: 'Cascadia Code',
557
- },
558
- beamer: {
559
- theme: 'default',
560
- colortheme: 'orchid',
561
- fonttheme: null,
562
- },
563
- },
564
-
565
- bauhaus: {
566
- name: 'bauhaus',
567
- displayName: 'Bauhaus',
568
- description: 'Geometric, primary colors inspired by Bauhaus design',
569
- colors: {
570
- primary: '#1D4ED8', // Blue 700
571
- secondary: '#DC2626', // Red 600
572
- accent: '#FACC15', // Yellow 400
573
- background: '#FAFAFA', // Neutral 50
574
- backgroundDark: '#1E293B',
575
- text: '#0F172A',
576
- textLight: '#F8FAFC',
577
- },
578
- fonts: {
579
- heading: 'Archivo',
580
- body: 'Rubik',
581
- mono: 'Overpass Mono',
582
- },
583
- beamer: {
584
- theme: 'default',
585
- colortheme: 'default',
586
- fonttheme: null,
587
- },
588
- },
589
- };
590
-
591
- /**
592
- * Get theme by name
593
- */
594
- export function getTheme(name: string): Theme | null {
595
- return THEMES[name] || null;
596
- }
597
-
598
- /**
599
- * Get all theme names
600
- */
601
- export function getThemeNames(): string[] {
602
- return Object.keys(THEMES);
603
- }
604
-
605
- /**
606
- * Get themes by category
607
- */
608
- export function getThemesByCategory(category: string): Theme[] {
609
- const categories: Record<string, string[]> = {
610
- minimal: ['metropolis', 'nordic', 'slate', 'paper', 'mono'],
611
- bold: ['electric', 'crimson', 'emerald', 'violet', 'amber'],
612
- dark: ['midnight', 'obsidian', 'carbon', 'noir'],
613
- earth: ['forest', 'terracotta', 'ocean'],
614
- trendy: ['neomint', 'gradient', 'bauhaus'],
615
- };
616
-
617
- const names = categories[category] || [];
618
- return names.map(name => THEMES[name]).filter(Boolean);
619
- }
620
-
621
- /**
622
- * Generate Beamer color definitions for a theme
623
- */
624
- export function generateBeamerColors(theme: Theme): string {
625
- const { colors } = theme;
626
-
627
- // Convert hex to RGB
628
- const hexToRgb = (hex: string): RGB => {
629
- const result = /^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(hex);
630
- return result ? {
631
- r: parseInt(result[1], 16),
632
- g: parseInt(result[2], 16),
633
- b: parseInt(result[3], 16),
634
- } : { r: 0, g: 0, b: 0 };
635
- };
636
-
637
- const primary = hexToRgb(colors.primary);
638
- const secondary = hexToRgb(colors.secondary);
639
- const accent = hexToRgb(colors.accent);
640
- const bg = hexToRgb(colors.background);
641
- const bgDark = hexToRgb(colors.backgroundDark);
642
- const text = hexToRgb(colors.text);
643
-
644
- return `
645
- % Theme: ${theme.displayName}
646
- % ${theme.description}
647
- \\definecolor{ThemePrimary}{RGB}{${primary.r},${primary.g},${primary.b}}
648
- \\definecolor{ThemeSecondary}{RGB}{${secondary.r},${secondary.g},${secondary.b}}
649
- \\definecolor{ThemeAccent}{RGB}{${accent.r},${accent.g},${accent.b}}
650
- \\definecolor{ThemeBackground}{RGB}{${bg.r},${bg.g},${bg.b}}
651
- \\definecolor{ThemeBackgroundDark}{RGB}{${bgDark.r},${bgDark.g},${bgDark.b}}
652
- \\definecolor{ThemeText}{RGB}{${text.r},${text.g},${text.b}}
653
-
654
- \\setbeamercolor{structure}{fg=ThemePrimary}
655
- \\setbeamercolor{frametitle}{fg=ThemePrimary,bg=ThemeBackground}
656
- \\setbeamercolor{title}{fg=ThemePrimary}
657
- \\setbeamercolor{subtitle}{fg=ThemeSecondary}
658
- \\setbeamercolor{normal text}{fg=ThemeText,bg=ThemeBackground}
659
- \\setbeamercolor{alerted text}{fg=ThemeAccent}
660
- \\setbeamercolor{example text}{fg=ThemeSecondary}
661
- `.trim();
662
- }
663
-
664
- /**
665
- * Generate CSS for PPTX reference doc
666
- */
667
- export function generatePptxCSS(theme: Theme): string {
668
- const { colors, fonts } = theme;
669
-
670
- return `
671
- /* Theme: ${theme.displayName} */
672
- /* ${theme.description} */
673
-
674
- :root {
675
- --theme-primary: ${colors.primary};
676
- --theme-secondary: ${colors.secondary};
677
- --theme-accent: ${colors.accent};
678
- --theme-background: ${colors.background};
679
- --theme-background-dark: ${colors.backgroundDark};
680
- --theme-text: ${colors.text};
681
- --theme-text-light: ${colors.textLight};
682
-
683
- --font-heading: '${fonts.heading}', sans-serif;
684
- --font-body: '${fonts.body}', sans-serif;
685
- --font-mono: '${fonts.mono}', monospace;
686
- }
687
-
688
- /* Slide styles */
689
- .dark {
690
- background-color: var(--theme-background-dark);
691
- color: var(--theme-text-light);
692
- }
693
-
694
- .cover, .thanks, .section {
695
- background-color: var(--theme-primary);
696
- color: var(--theme-text-light);
697
- text-align: center;
698
- }
699
-
700
- .accent {
701
- background-color: var(--theme-accent);
702
- color: var(--theme-text);
703
- }
704
- `.trim();
705
- }
706
-
707
- /**
708
- * Format theme info for display
709
- */
710
- export function formatThemeInfo(theme: Theme): string {
711
- const lines = [
712
- `${theme.displayName}`,
713
- ` ${theme.description}`,
714
- ` Colors: ${theme.colors.primary} (primary), ${theme.colors.accent} (accent)`,
715
- ` Fonts: ${theme.fonts.heading} / ${theme.fonts.body}`,
716
- ];
717
- return lines.join('\n');
718
- }
719
-
720
- /**
721
- * List all themes with descriptions
722
- */
723
- export function listThemes(): string {
724
- const categories = [
725
- { name: 'Minimal & Professional', themes: ['metropolis', 'nordic', 'slate', 'paper', 'mono'] },
726
- { name: 'Bold & Modern', themes: ['electric', 'crimson', 'emerald', 'violet', 'amber'] },
727
- { name: 'Dark Mode', themes: ['midnight', 'obsidian', 'carbon', 'noir'] },
728
- { name: 'Earth & Nature', themes: ['forest', 'terracotta', 'ocean'] },
729
- { name: 'Contemporary', themes: ['neomint', 'gradient', 'bauhaus'] },
730
- ];
731
-
732
- const lines: string[] = [];
733
- for (const cat of categories) {
734
- lines.push(`\n${cat.name}:`);
735
- for (const name of cat.themes) {
736
- const theme = THEMES[name];
737
- lines.push(` ${name.padEnd(12)} - ${theme.description}`);
738
- }
739
- }
740
-
741
- return lines.join('\n');
742
- }
1
+ /**
2
+ * Slide Themes for Beamer and PPTX
3
+ *
4
+ * 20 professionally designed themes based on modern design principles:
5
+ * - Bold, confident typography (2025-2026 trend)
6
+ * - Curated color palettes (monochrome, earth tones, neo-mint, dark mode)
7
+ * - Clean sans-serif fonts for readability
8
+ * - Consistent visual hierarchy
9
+ *
10
+ * Each theme includes:
11
+ * - Primary, secondary, accent colors
12
+ * - Background and text colors
13
+ * - Font recommendations
14
+ * - Beamer configuration
15
+ */
16
+
17
+ /**
18
+ * Theme colors
19
+ */
20
+ interface ThemeColors {
21
+ primary: string;
22
+ secondary: string;
23
+ accent: string;
24
+ background: string;
25
+ backgroundDark: string;
26
+ text: string;
27
+ textLight: string;
28
+ }
29
+
30
+ /**
31
+ * Theme fonts
32
+ */
33
+ interface ThemeFonts {
34
+ heading: string;
35
+ body: string;
36
+ mono: string;
37
+ }
38
+
39
+ /**
40
+ * Beamer settings
41
+ */
42
+ interface BeamerSettings {
43
+ theme: string;
44
+ colortheme: string | null;
45
+ fonttheme: string | null;
46
+ }
47
+
48
+ /**
49
+ * Complete theme definition
50
+ */
51
+ interface Theme {
52
+ name: string;
53
+ displayName: string;
54
+ description: string;
55
+ colors: ThemeColors;
56
+ fonts: ThemeFonts;
57
+ beamer: BeamerSettings;
58
+ }
59
+
60
+ /**
61
+ * RGB color values
62
+ */
63
+ interface RGB {
64
+ r: number;
65
+ g: number;
66
+ b: number;
67
+ }
68
+
69
+ export const THEMES: Record<string, Theme> = {
70
+ // ============================================
71
+ // MINIMAL & PROFESSIONAL (1-5)
72
+ // ============================================
73
+
74
+ metropolis: {
75
+ name: 'metropolis',
76
+ displayName: 'Metropolis',
77
+ description: 'Clean, modern minimal theme inspired by the popular Beamer theme',
78
+ colors: {
79
+ primary: '#23373B', // Dark teal-gray
80
+ secondary: '#EB811B', // Orange accent
81
+ accent: '#14B03D', // Green
82
+ background: '#FAFAFA', // Off-white
83
+ backgroundDark: '#23373B',
84
+ text: '#23373B',
85
+ textLight: '#FAFAFA',
86
+ },
87
+ fonts: {
88
+ heading: 'Fira Sans',
89
+ body: 'Fira Sans',
90
+ mono: 'Fira Mono',
91
+ },
92
+ beamer: {
93
+ theme: 'metropolis',
94
+ colortheme: null,
95
+ fonttheme: null,
96
+ },
97
+ },
98
+
99
+ nordic: {
100
+ name: 'nordic',
101
+ displayName: 'Nordic',
102
+ description: 'Scandinavian-inspired minimal design with soft contrasts',
103
+ colors: {
104
+ primary: '#2E3440', // Polar Night
105
+ secondary: '#5E81AC', // Frost blue
106
+ accent: '#88C0D0', // Aurora cyan
107
+ background: '#ECEFF4', // Snow
108
+ backgroundDark: '#2E3440',
109
+ text: '#2E3440',
110
+ textLight: '#ECEFF4',
111
+ },
112
+ fonts: {
113
+ heading: 'Inter',
114
+ body: 'Inter',
115
+ mono: 'JetBrains Mono',
116
+ },
117
+ beamer: {
118
+ theme: 'default',
119
+ colortheme: 'dove',
120
+ fonttheme: null,
121
+ },
122
+ },
123
+
124
+ slate: {
125
+ name: 'slate',
126
+ displayName: 'Slate',
127
+ description: 'Professional gray tones with subtle blue accent',
128
+ colors: {
129
+ primary: '#334155', // Slate 700
130
+ secondary: '#64748B', // Slate 500
131
+ accent: '#3B82F6', // Blue 500
132
+ background: '#F8FAFC', // Slate 50
133
+ backgroundDark: '#1E293B',
134
+ text: '#1E293B',
135
+ textLight: '#F1F5F9',
136
+ },
137
+ fonts: {
138
+ heading: 'IBM Plex Sans',
139
+ body: 'IBM Plex Sans',
140
+ mono: 'IBM Plex Mono',
141
+ },
142
+ beamer: {
143
+ theme: 'default',
144
+ colortheme: 'dove',
145
+ fonttheme: null,
146
+ },
147
+ },
148
+
149
+ paper: {
150
+ name: 'paper',
151
+ displayName: 'Paper',
152
+ description: 'Warm, academic feel with sepia undertones',
153
+ colors: {
154
+ primary: '#44403C', // Stone 700
155
+ secondary: '#78716C', // Stone 500
156
+ accent: '#B45309', // Amber 700
157
+ background: '#FAFAF9', // Stone 50
158
+ backgroundDark: '#292524',
159
+ text: '#1C1917',
160
+ textLight: '#FAFAF9',
161
+ },
162
+ fonts: {
163
+ heading: 'Source Sans Pro',
164
+ body: 'Source Serif Pro',
165
+ mono: 'Source Code Pro',
166
+ },
167
+ beamer: {
168
+ theme: 'default',
169
+ colortheme: 'seagull',
170
+ fonttheme: null,
171
+ },
172
+ },
173
+
174
+ mono: {
175
+ name: 'mono',
176
+ displayName: 'Mono',
177
+ description: 'Pure black and white for maximum contrast',
178
+ colors: {
179
+ primary: '#000000',
180
+ secondary: '#404040',
181
+ accent: '#000000',
182
+ background: '#FFFFFF',
183
+ backgroundDark: '#000000',
184
+ text: '#000000',
185
+ textLight: '#FFFFFF',
186
+ },
187
+ fonts: {
188
+ heading: 'Helvetica Neue',
189
+ body: 'Helvetica Neue',
190
+ mono: 'Menlo',
191
+ },
192
+ beamer: {
193
+ theme: 'default',
194
+ colortheme: 'dove',
195
+ fonttheme: null,
196
+ },
197
+ },
198
+
199
+ // ============================================
200
+ // BOLD & MODERN (6-10)
201
+ // ============================================
202
+
203
+ electric: {
204
+ name: 'electric',
205
+ displayName: 'Electric',
206
+ description: 'Bold electric blue monochrome for high-impact presentations',
207
+ colors: {
208
+ primary: '#2563EB', // Blue 600
209
+ secondary: '#3B82F6', // Blue 500
210
+ accent: '#60A5FA', // Blue 400
211
+ background: '#EFF6FF', // Blue 50
212
+ backgroundDark: '#1E3A8A',
213
+ text: '#1E3A8A',
214
+ textLight: '#EFF6FF',
215
+ },
216
+ fonts: {
217
+ heading: 'Montserrat',
218
+ body: 'Open Sans',
219
+ mono: 'Fira Code',
220
+ },
221
+ beamer: {
222
+ theme: 'default',
223
+ colortheme: 'whale',
224
+ fonttheme: null,
225
+ },
226
+ },
227
+
228
+ crimson: {
229
+ name: 'crimson',
230
+ displayName: 'Crimson',
231
+ description: 'Deep red monochrome for bold, confident statements',
232
+ colors: {
233
+ primary: '#DC2626', // Red 600
234
+ secondary: '#B91C1C', // Red 700
235
+ accent: '#F87171', // Red 400
236
+ background: '#FEF2F2', // Red 50
237
+ backgroundDark: '#7F1D1D',
238
+ text: '#7F1D1D',
239
+ textLight: '#FEF2F2',
240
+ },
241
+ fonts: {
242
+ heading: 'Raleway',
243
+ body: 'Lato',
244
+ mono: 'Roboto Mono',
245
+ },
246
+ beamer: {
247
+ theme: 'default',
248
+ colortheme: 'crane',
249
+ fonttheme: null,
250
+ },
251
+ },
252
+
253
+ emerald: {
254
+ name: 'emerald',
255
+ displayName: 'Emerald',
256
+ description: 'Rich green for environmental or growth-focused topics',
257
+ colors: {
258
+ primary: '#059669', // Emerald 600
259
+ secondary: '#10B981', // Emerald 500
260
+ accent: '#34D399', // Emerald 400
261
+ background: '#ECFDF5', // Emerald 50
262
+ backgroundDark: '#064E3B',
263
+ text: '#064E3B',
264
+ textLight: '#ECFDF5',
265
+ },
266
+ fonts: {
267
+ heading: 'Poppins',
268
+ body: 'Nunito',
269
+ mono: 'Inconsolata',
270
+ },
271
+ beamer: {
272
+ theme: 'default',
273
+ colortheme: 'spruce',
274
+ fonttheme: null,
275
+ },
276
+ },
277
+
278
+ violet: {
279
+ name: 'violet',
280
+ displayName: 'Violet',
281
+ description: 'Deep purple for creative and innovative presentations',
282
+ colors: {
283
+ primary: '#7C3AED', // Violet 600
284
+ secondary: '#8B5CF6', // Violet 500
285
+ accent: '#A78BFA', // Violet 400
286
+ background: '#F5F3FF', // Violet 50
287
+ backgroundDark: '#4C1D95',
288
+ text: '#4C1D95',
289
+ textLight: '#F5F3FF',
290
+ },
291
+ fonts: {
292
+ heading: 'Space Grotesk',
293
+ body: 'DM Sans',
294
+ mono: 'JetBrains Mono',
295
+ },
296
+ beamer: {
297
+ theme: 'default',
298
+ colortheme: 'orchid',
299
+ fonttheme: null,
300
+ },
301
+ },
302
+
303
+ amber: {
304
+ name: 'amber',
305
+ displayName: 'Amber',
306
+ description: 'Warm golden tones for engaging, energetic presentations',
307
+ colors: {
308
+ primary: '#D97706', // Amber 600
309
+ secondary: '#F59E0B', // Amber 500
310
+ accent: '#FBBF24', // Amber 400
311
+ background: '#FFFBEB', // Amber 50
312
+ backgroundDark: '#78350F',
313
+ text: '#78350F',
314
+ textLight: '#FFFBEB',
315
+ },
316
+ fonts: {
317
+ heading: 'Outfit',
318
+ body: 'Work Sans',
319
+ mono: 'Source Code Pro',
320
+ },
321
+ beamer: {
322
+ theme: 'default',
323
+ colortheme: 'beaver',
324
+ fonttheme: null,
325
+ },
326
+ },
327
+
328
+ // ============================================
329
+ // DARK MODE (11-14)
330
+ // ============================================
331
+
332
+ midnight: {
333
+ name: 'midnight',
334
+ displayName: 'Midnight',
335
+ description: 'Deep dark mode with blue accents',
336
+ colors: {
337
+ primary: '#60A5FA', // Blue 400
338
+ secondary: '#93C5FD', // Blue 300
339
+ accent: '#3B82F6', // Blue 500
340
+ background: '#0F172A', // Slate 900
341
+ backgroundDark: '#020617',
342
+ text: '#E2E8F0',
343
+ textLight: '#F1F5F9',
344
+ },
345
+ fonts: {
346
+ heading: 'Inter',
347
+ body: 'Inter',
348
+ mono: 'Fira Code',
349
+ },
350
+ beamer: {
351
+ theme: 'default',
352
+ colortheme: 'owl',
353
+ fonttheme: null,
354
+ },
355
+ },
356
+
357
+ obsidian: {
358
+ name: 'obsidian',
359
+ displayName: 'Obsidian',
360
+ description: 'Pure dark mode with subtle purple glow',
361
+ colors: {
362
+ primary: '#A78BFA', // Violet 400
363
+ secondary: '#C4B5FD', // Violet 300
364
+ accent: '#8B5CF6', // Violet 500
365
+ background: '#18181B', // Zinc 900
366
+ backgroundDark: '#09090B',
367
+ text: '#E4E4E7',
368
+ textLight: '#FAFAFA',
369
+ },
370
+ fonts: {
371
+ heading: 'Manrope',
372
+ body: 'Manrope',
373
+ mono: 'JetBrains Mono',
374
+ },
375
+ beamer: {
376
+ theme: 'default',
377
+ colortheme: 'owl',
378
+ fonttheme: null,
379
+ },
380
+ },
381
+
382
+ carbon: {
383
+ name: 'carbon',
384
+ displayName: 'Carbon',
385
+ description: 'Tech-forward dark theme with green terminal accent',
386
+ colors: {
387
+ primary: '#4ADE80', // Green 400
388
+ secondary: '#86EFAC', // Green 300
389
+ accent: '#22C55E', // Green 500
390
+ background: '#171717', // Neutral 900
391
+ backgroundDark: '#0A0A0A',
392
+ text: '#E5E5E5',
393
+ textLight: '#FAFAFA',
394
+ },
395
+ fonts: {
396
+ heading: 'Roboto',
397
+ body: 'Roboto',
398
+ mono: 'Fira Mono',
399
+ },
400
+ beamer: {
401
+ theme: 'default',
402
+ colortheme: 'owl',
403
+ fonttheme: null,
404
+ },
405
+ },
406
+
407
+ noir: {
408
+ name: 'noir',
409
+ displayName: 'Noir',
410
+ description: 'Elegant dark mode with warm amber highlights',
411
+ colors: {
412
+ primary: '#FBBF24', // Amber 400
413
+ secondary: '#FCD34D', // Amber 300
414
+ accent: '#F59E0B', // Amber 500
415
+ background: '#1C1917', // Stone 900
416
+ backgroundDark: '#0C0A09',
417
+ text: '#E7E5E4',
418
+ textLight: '#FAFAF9',
419
+ },
420
+ fonts: {
421
+ heading: 'Playfair Display',
422
+ body: 'Lato',
423
+ mono: 'IBM Plex Mono',
424
+ },
425
+ beamer: {
426
+ theme: 'default',
427
+ colortheme: 'owl',
428
+ fonttheme: null,
429
+ },
430
+ },
431
+
432
+ // ============================================
433
+ // EARTH & NATURE (15-17)
434
+ // ============================================
435
+
436
+ forest: {
437
+ name: 'forest',
438
+ displayName: 'Forest',
439
+ description: 'Deep greens and earthy browns for natural topics',
440
+ colors: {
441
+ primary: '#166534', // Green 800
442
+ secondary: '#15803D', // Green 700
443
+ accent: '#A3E635', // Lime 400
444
+ background: '#F0FDF4', // Green 50
445
+ backgroundDark: '#14532D',
446
+ text: '#14532D',
447
+ textLight: '#F0FDF4',
448
+ },
449
+ fonts: {
450
+ heading: 'Josefin Sans',
451
+ body: 'Merriweather Sans',
452
+ mono: 'Inconsolata',
453
+ },
454
+ beamer: {
455
+ theme: 'default',
456
+ colortheme: 'spruce',
457
+ fonttheme: null,
458
+ },
459
+ },
460
+
461
+ terracotta: {
462
+ name: 'terracotta',
463
+ displayName: 'Terracotta',
464
+ description: 'Warm earth tones with Mediterranean warmth',
465
+ colors: {
466
+ primary: '#C2410C', // Orange 700
467
+ secondary: '#EA580C', // Orange 600
468
+ accent: '#FDBA74', // Orange 300
469
+ background: '#FFF7ED', // Orange 50
470
+ backgroundDark: '#7C2D12',
471
+ text: '#7C2D12',
472
+ textLight: '#FFF7ED',
473
+ },
474
+ fonts: {
475
+ heading: 'Cormorant Garamond',
476
+ body: 'Mulish',
477
+ mono: 'Cousine',
478
+ },
479
+ beamer: {
480
+ theme: 'default',
481
+ colortheme: 'beaver',
482
+ fonttheme: null,
483
+ },
484
+ },
485
+
486
+ ocean: {
487
+ name: 'ocean',
488
+ displayName: 'Ocean',
489
+ description: 'Deep teal and aqua for marine and water themes',
490
+ colors: {
491
+ primary: '#0D9488', // Teal 600
492
+ secondary: '#14B8A6', // Teal 500
493
+ accent: '#5EEAD4', // Teal 300
494
+ background: '#F0FDFA', // Teal 50
495
+ backgroundDark: '#134E4A',
496
+ text: '#134E4A',
497
+ textLight: '#F0FDFA',
498
+ },
499
+ fonts: {
500
+ heading: 'Quicksand',
501
+ body: 'Nunito Sans',
502
+ mono: 'Hack',
503
+ },
504
+ beamer: {
505
+ theme: 'default',
506
+ colortheme: 'seahorse',
507
+ fonttheme: null,
508
+ },
509
+ },
510
+
511
+ // ============================================
512
+ // CONTEMPORARY & TRENDY (18-20)
513
+ // ============================================
514
+
515
+ neomint: {
516
+ name: 'neomint',
517
+ displayName: 'Neo Mint',
518
+ description: '2026 trend: soft futuristic mint with pastel accents',
519
+ colors: {
520
+ primary: '#10B981', // Emerald 500
521
+ secondary: '#6EE7B7', // Emerald 300
522
+ accent: '#F472B6', // Pink 400
523
+ background: '#F0FDF4', // Green 50
524
+ backgroundDark: '#064E3B',
525
+ text: '#064E3B',
526
+ textLight: '#ECFDF5',
527
+ },
528
+ fonts: {
529
+ heading: 'Plus Jakarta Sans',
530
+ body: 'Plus Jakarta Sans',
531
+ mono: 'Space Mono',
532
+ },
533
+ beamer: {
534
+ theme: 'default',
535
+ colortheme: 'default',
536
+ fonttheme: null,
537
+ },
538
+ },
539
+
540
+ gradient: {
541
+ name: 'gradient',
542
+ displayName: 'Gradient',
543
+ description: 'Modern gradient-inspired with pink to purple flow',
544
+ colors: {
545
+ primary: '#EC4899', // Pink 500
546
+ secondary: '#8B5CF6', // Violet 500
547
+ accent: '#06B6D4', // Cyan 500
548
+ background: '#FDF4FF', // Fuchsia 50
549
+ backgroundDark: '#701A75',
550
+ text: '#701A75',
551
+ textLight: '#FDF4FF',
552
+ },
553
+ fonts: {
554
+ heading: 'Sora',
555
+ body: 'Outfit',
556
+ mono: 'Cascadia Code',
557
+ },
558
+ beamer: {
559
+ theme: 'default',
560
+ colortheme: 'orchid',
561
+ fonttheme: null,
562
+ },
563
+ },
564
+
565
+ bauhaus: {
566
+ name: 'bauhaus',
567
+ displayName: 'Bauhaus',
568
+ description: 'Geometric, primary colors inspired by Bauhaus design',
569
+ colors: {
570
+ primary: '#1D4ED8', // Blue 700
571
+ secondary: '#DC2626', // Red 600
572
+ accent: '#FACC15', // Yellow 400
573
+ background: '#FAFAFA', // Neutral 50
574
+ backgroundDark: '#1E293B',
575
+ text: '#0F172A',
576
+ textLight: '#F8FAFC',
577
+ },
578
+ fonts: {
579
+ heading: 'Archivo',
580
+ body: 'Rubik',
581
+ mono: 'Overpass Mono',
582
+ },
583
+ beamer: {
584
+ theme: 'default',
585
+ colortheme: 'default',
586
+ fonttheme: null,
587
+ },
588
+ },
589
+ };
590
+
591
+ /**
592
+ * Get theme by name
593
+ */
594
+ export function getTheme(name: string): Theme | null {
595
+ return THEMES[name] || null;
596
+ }
597
+
598
+ /**
599
+ * Get all theme names
600
+ */
601
+ export function getThemeNames(): string[] {
602
+ return Object.keys(THEMES);
603
+ }
604
+
605
+ /**
606
+ * Get themes by category
607
+ */
608
+ export function getThemesByCategory(category: string): Theme[] {
609
+ const categories: Record<string, string[]> = {
610
+ minimal: ['metropolis', 'nordic', 'slate', 'paper', 'mono'],
611
+ bold: ['electric', 'crimson', 'emerald', 'violet', 'amber'],
612
+ dark: ['midnight', 'obsidian', 'carbon', 'noir'],
613
+ earth: ['forest', 'terracotta', 'ocean'],
614
+ trendy: ['neomint', 'gradient', 'bauhaus'],
615
+ };
616
+
617
+ const names = categories[category] || [];
618
+ return names.map(name => THEMES[name]).filter(Boolean);
619
+ }
620
+
621
+ /**
622
+ * Generate Beamer color definitions for a theme
623
+ */
624
+ export function generateBeamerColors(theme: Theme): string {
625
+ const { colors } = theme;
626
+
627
+ // Convert hex to RGB
628
+ const hexToRgb = (hex: string): RGB => {
629
+ const result = /^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(hex);
630
+ return result ? {
631
+ r: parseInt(result[1], 16),
632
+ g: parseInt(result[2], 16),
633
+ b: parseInt(result[3], 16),
634
+ } : { r: 0, g: 0, b: 0 };
635
+ };
636
+
637
+ const primary = hexToRgb(colors.primary);
638
+ const secondary = hexToRgb(colors.secondary);
639
+ const accent = hexToRgb(colors.accent);
640
+ const bg = hexToRgb(colors.background);
641
+ const bgDark = hexToRgb(colors.backgroundDark);
642
+ const text = hexToRgb(colors.text);
643
+
644
+ return `
645
+ % Theme: ${theme.displayName}
646
+ % ${theme.description}
647
+ \\definecolor{ThemePrimary}{RGB}{${primary.r},${primary.g},${primary.b}}
648
+ \\definecolor{ThemeSecondary}{RGB}{${secondary.r},${secondary.g},${secondary.b}}
649
+ \\definecolor{ThemeAccent}{RGB}{${accent.r},${accent.g},${accent.b}}
650
+ \\definecolor{ThemeBackground}{RGB}{${bg.r},${bg.g},${bg.b}}
651
+ \\definecolor{ThemeBackgroundDark}{RGB}{${bgDark.r},${bgDark.g},${bgDark.b}}
652
+ \\definecolor{ThemeText}{RGB}{${text.r},${text.g},${text.b}}
653
+
654
+ \\setbeamercolor{structure}{fg=ThemePrimary}
655
+ \\setbeamercolor{frametitle}{fg=ThemePrimary,bg=ThemeBackground}
656
+ \\setbeamercolor{title}{fg=ThemePrimary}
657
+ \\setbeamercolor{subtitle}{fg=ThemeSecondary}
658
+ \\setbeamercolor{normal text}{fg=ThemeText,bg=ThemeBackground}
659
+ \\setbeamercolor{alerted text}{fg=ThemeAccent}
660
+ \\setbeamercolor{example text}{fg=ThemeSecondary}
661
+ `.trim();
662
+ }
663
+
664
+ /**
665
+ * Generate CSS for PPTX reference doc
666
+ */
667
+ export function generatePptxCSS(theme: Theme): string {
668
+ const { colors, fonts } = theme;
669
+
670
+ return `
671
+ /* Theme: ${theme.displayName} */
672
+ /* ${theme.description} */
673
+
674
+ :root {
675
+ --theme-primary: ${colors.primary};
676
+ --theme-secondary: ${colors.secondary};
677
+ --theme-accent: ${colors.accent};
678
+ --theme-background: ${colors.background};
679
+ --theme-background-dark: ${colors.backgroundDark};
680
+ --theme-text: ${colors.text};
681
+ --theme-text-light: ${colors.textLight};
682
+
683
+ --font-heading: '${fonts.heading}', sans-serif;
684
+ --font-body: '${fonts.body}', sans-serif;
685
+ --font-mono: '${fonts.mono}', monospace;
686
+ }
687
+
688
+ /* Slide styles */
689
+ .dark {
690
+ background-color: var(--theme-background-dark);
691
+ color: var(--theme-text-light);
692
+ }
693
+
694
+ .cover, .thanks, .section {
695
+ background-color: var(--theme-primary);
696
+ color: var(--theme-text-light);
697
+ text-align: center;
698
+ }
699
+
700
+ .accent {
701
+ background-color: var(--theme-accent);
702
+ color: var(--theme-text);
703
+ }
704
+ `.trim();
705
+ }
706
+
707
+ /**
708
+ * Format theme info for display
709
+ */
710
+ export function formatThemeInfo(theme: Theme): string {
711
+ const lines = [
712
+ `${theme.displayName}`,
713
+ ` ${theme.description}`,
714
+ ` Colors: ${theme.colors.primary} (primary), ${theme.colors.accent} (accent)`,
715
+ ` Fonts: ${theme.fonts.heading} / ${theme.fonts.body}`,
716
+ ];
717
+ return lines.join('\n');
718
+ }
719
+
720
+ /**
721
+ * List all themes with descriptions
722
+ */
723
+ export function listThemes(): string {
724
+ const categories = [
725
+ { name: 'Minimal & Professional', themes: ['metropolis', 'nordic', 'slate', 'paper', 'mono'] },
726
+ { name: 'Bold & Modern', themes: ['electric', 'crimson', 'emerald', 'violet', 'amber'] },
727
+ { name: 'Dark Mode', themes: ['midnight', 'obsidian', 'carbon', 'noir'] },
728
+ { name: 'Earth & Nature', themes: ['forest', 'terracotta', 'ocean'] },
729
+ { name: 'Contemporary', themes: ['neomint', 'gradient', 'bauhaus'] },
730
+ ];
731
+
732
+ const lines: string[] = [];
733
+ for (const cat of categories) {
734
+ lines.push(`\n${cat.name}:`);
735
+ for (const name of cat.themes) {
736
+ const theme = THEMES[name];
737
+ lines.push(` ${name.padEnd(12)} - ${theme.description}`);
738
+ }
739
+ }
740
+
741
+ return lines.join('\n');
742
+ }