docrev 0.11.3 → 0.12.0

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 (193) hide show
  1. package/CHANGELOG.md +22 -0
  2. package/LICENSE +21 -0
  3. package/dist/bin/rev.js +29 -21
  4. package/dist/bin/rev.js.map +1 -1
  5. package/dist/lib/build.d.ts +43 -0
  6. package/dist/lib/build.d.ts.map +1 -1
  7. package/dist/lib/build.js +175 -5
  8. package/dist/lib/build.js.map +1 -1
  9. package/dist/lib/commands/build.d.ts.map +1 -1
  10. package/dist/lib/commands/build.js +39 -125
  11. package/dist/lib/commands/build.js.map +1 -1
  12. package/dist/lib/commands/comments.js +3 -3
  13. package/dist/lib/commands/comments.js.map +1 -1
  14. package/dist/lib/commands/context.d.ts +12 -1
  15. package/dist/lib/commands/context.d.ts.map +1 -1
  16. package/dist/lib/commands/context.js +34 -1
  17. package/dist/lib/commands/context.js.map +1 -1
  18. package/dist/lib/commands/merge-resolve.js +1 -1
  19. package/dist/lib/commands/merge-resolve.js.map +1 -1
  20. package/dist/lib/commands/quality.js +2 -2
  21. package/dist/lib/commands/quality.js.map +1 -1
  22. package/dist/lib/commands/sections.js +1 -1
  23. package/dist/lib/commands/sections.js.map +1 -1
  24. package/dist/lib/commands/text-ops.js +1 -1
  25. package/dist/lib/commands/text-ops.js.map +1 -1
  26. package/dist/lib/commands/utilities.d.ts.map +1 -1
  27. package/dist/lib/commands/utilities.js +5 -2
  28. package/dist/lib/commands/utilities.js.map +1 -1
  29. package/dist/lib/commands/word-tools.js +2 -2
  30. package/dist/lib/commands/word-tools.js.map +1 -1
  31. package/dist/lib/crossref.d.ts.map +1 -1
  32. package/dist/lib/crossref.js +12 -41
  33. package/dist/lib/crossref.js.map +1 -1
  34. package/dist/lib/csl.d.ts.map +1 -1
  35. package/dist/lib/csl.js +14 -22
  36. package/dist/lib/csl.js.map +1 -1
  37. package/dist/lib/diff-engine.js +1 -1
  38. package/dist/lib/diff-engine.js.map +1 -1
  39. package/dist/lib/equations.d.ts.map +1 -1
  40. package/dist/lib/equations.js +12 -3
  41. package/dist/lib/equations.js.map +1 -1
  42. package/dist/lib/errors.d.ts.map +1 -1
  43. package/dist/lib/errors.js +1 -30
  44. package/dist/lib/errors.js.map +1 -1
  45. package/dist/lib/image-registry.d.ts.map +1 -1
  46. package/dist/lib/image-registry.js +4 -0
  47. package/dist/lib/image-registry.js.map +1 -1
  48. package/dist/lib/import.d.ts +1 -1
  49. package/dist/lib/import.d.ts.map +1 -1
  50. package/dist/lib/import.js +1 -1
  51. package/dist/lib/import.js.map +1 -1
  52. package/dist/lib/input.d.ts +0 -11
  53. package/dist/lib/input.d.ts.map +1 -1
  54. package/dist/lib/input.js +0 -35
  55. package/dist/lib/input.js.map +1 -1
  56. package/dist/lib/merge.d.ts.map +1 -1
  57. package/dist/lib/merge.js +9 -1
  58. package/dist/lib/merge.js.map +1 -1
  59. package/dist/lib/ooxml.d.ts +22 -0
  60. package/dist/lib/ooxml.d.ts.map +1 -1
  61. package/dist/lib/ooxml.js +130 -0
  62. package/dist/lib/ooxml.js.map +1 -1
  63. package/dist/lib/orcid.d.ts.map +1 -1
  64. package/dist/lib/orcid.js +16 -7
  65. package/dist/lib/orcid.js.map +1 -1
  66. package/dist/lib/plugins.d.ts.map +1 -1
  67. package/dist/lib/plugins.js +8 -4
  68. package/dist/lib/plugins.js.map +1 -1
  69. package/dist/lib/protect-restore.d.ts.map +1 -1
  70. package/dist/lib/protect-restore.js +7 -5
  71. package/dist/lib/protect-restore.js.map +1 -1
  72. package/dist/lib/restore-references.d.ts.map +1 -1
  73. package/dist/lib/restore-references.js +25 -3
  74. package/dist/lib/restore-references.js.map +1 -1
  75. package/dist/lib/schema.d.ts.map +1 -1
  76. package/dist/lib/schema.js +1 -19
  77. package/dist/lib/schema.js.map +1 -1
  78. package/dist/lib/slides.js +1 -1
  79. package/dist/lib/slides.js.map +1 -1
  80. package/dist/lib/spelling.js +1 -1
  81. package/dist/lib/spelling.js.map +1 -1
  82. package/dist/lib/tui.js +0 -1
  83. package/dist/lib/tui.js.map +1 -1
  84. package/dist/lib/utils.d.ts +14 -0
  85. package/dist/lib/utils.d.ts.map +1 -1
  86. package/dist/lib/utils.js +41 -0
  87. package/dist/lib/utils.js.map +1 -1
  88. package/dist/lib/word-extraction.d.ts +5 -5
  89. package/dist/lib/word-extraction.d.ts.map +1 -1
  90. package/dist/lib/word-extraction.js +25 -106
  91. package/dist/lib/word-extraction.js.map +1 -1
  92. package/dist/lib/word.d.ts +14 -38
  93. package/dist/lib/word.d.ts.map +1 -1
  94. package/dist/lib/word.js +24 -179
  95. package/dist/lib/word.js.map +1 -1
  96. package/dist/lib/wordcomments.d.ts.map +1 -1
  97. package/dist/lib/wordcomments.js +9 -7
  98. package/dist/lib/wordcomments.js.map +1 -1
  99. package/package.json +17 -6
  100. package/.gitattributes +0 -1
  101. package/PLAN-tables-and-postprocess.md +0 -850
  102. package/bin/rev.ts +0 -145
  103. package/docs-src/build.py +0 -113
  104. package/docs-src/extra.css +0 -208
  105. package/docs-src/md-to-html.lua +0 -6
  106. package/docs-src/template.html +0 -116
  107. package/eslint.config.js +0 -27
  108. package/lib/anchor-match.ts +0 -307
  109. package/lib/annotations.ts +0 -695
  110. package/lib/build.ts +0 -2047
  111. package/lib/citations.ts +0 -160
  112. package/lib/commands/build.ts +0 -885
  113. package/lib/commands/citations.ts +0 -515
  114. package/lib/commands/comments.ts +0 -1077
  115. package/lib/commands/context.ts +0 -185
  116. package/lib/commands/core.ts +0 -328
  117. package/lib/commands/doi.ts +0 -451
  118. package/lib/commands/file-ops.ts +0 -372
  119. package/lib/commands/history.ts +0 -320
  120. package/lib/commands/index.ts +0 -87
  121. package/lib/commands/init.ts +0 -259
  122. package/lib/commands/merge-resolve.ts +0 -378
  123. package/lib/commands/preview.ts +0 -178
  124. package/lib/commands/project-info.ts +0 -244
  125. package/lib/commands/quality.ts +0 -517
  126. package/lib/commands/response.ts +0 -454
  127. package/lib/commands/section-boundaries.ts +0 -82
  128. package/lib/commands/sections.ts +0 -451
  129. package/lib/commands/sync.ts +0 -689
  130. package/lib/commands/text-ops.ts +0 -449
  131. package/lib/commands/utilities.ts +0 -448
  132. package/lib/commands/verify-anchors.ts +0 -272
  133. package/lib/commands/word-tools.ts +0 -340
  134. package/lib/comment-realign.ts +0 -99
  135. package/lib/config.ts +0 -84
  136. package/lib/crossref.ts +0 -781
  137. package/lib/csl.ts +0 -191
  138. package/lib/dependencies.ts +0 -132
  139. package/lib/diff-engine.ts +0 -465
  140. package/lib/doi-cache.ts +0 -115
  141. package/lib/doi.ts +0 -879
  142. package/lib/equations.ts +0 -506
  143. package/lib/errors.ts +0 -350
  144. package/lib/format.ts +0 -541
  145. package/lib/git.ts +0 -326
  146. package/lib/grammar.ts +0 -303
  147. package/lib/image-registry.ts +0 -180
  148. package/lib/import.ts +0 -932
  149. package/lib/input.ts +0 -174
  150. package/lib/journals.ts +0 -543
  151. package/lib/macro-filter.lua +0 -201
  152. package/lib/macros.ts +0 -273
  153. package/lib/merge.ts +0 -633
  154. package/lib/ooxml.ts +0 -768
  155. package/lib/orcid.ts +0 -144
  156. package/lib/pdf-comments.ts +0 -263
  157. package/lib/pdf-import.ts +0 -524
  158. package/lib/plugins.ts +0 -362
  159. package/lib/postprocess.ts +0 -188
  160. package/lib/pptx-color-filter.lua +0 -37
  161. package/lib/pptx-template.ts +0 -469
  162. package/lib/pptx-themes/academic.pptx +0 -0
  163. package/lib/pptx-themes/corporate.pptx +0 -0
  164. package/lib/pptx-themes/dark.pptx +0 -0
  165. package/lib/pptx-themes/default.pptx +0 -0
  166. package/lib/pptx-themes/minimal.pptx +0 -0
  167. package/lib/pptx-themes/plant.pptx +0 -0
  168. package/lib/pptx-themes.ts +0 -483
  169. package/lib/protect-restore.ts +0 -520
  170. package/lib/rate-limiter.ts +0 -127
  171. package/lib/response.ts +0 -200
  172. package/lib/restore-references.ts +0 -240
  173. package/lib/review.ts +0 -327
  174. package/lib/schema.ts +0 -494
  175. package/lib/scientific-words.ts +0 -73
  176. package/lib/sections.ts +0 -428
  177. package/lib/slides.ts +0 -756
  178. package/lib/spelling.ts +0 -334
  179. package/lib/templates.ts +0 -526
  180. package/lib/themes.ts +0 -742
  181. package/lib/trackchanges.ts +0 -166
  182. package/lib/tui.ts +0 -450
  183. package/lib/types.ts +0 -546
  184. package/lib/undo.ts +0 -250
  185. package/lib/utils.ts +0 -69
  186. package/lib/variables.ts +0 -179
  187. package/lib/word-extraction.ts +0 -525
  188. package/lib/word.ts +0 -526
  189. package/lib/wordcomments.ts +0 -789
  190. package/mkdocs.yml +0 -64
  191. package/scripts/postbuild.js +0 -47
  192. package/tsconfig.json +0 -26
  193. package/types/index.d.ts +0 -531
package/lib/themes.ts DELETED
@@ -1,742 +0,0 @@
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
- }