@mks2508/better-logger 0.14.0-alpha.1 → 1.0.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 (145) hide show
  1. package/dist/chunks/{Logger-BW-kn5_7.js → Logger-CTAaDeZi.js} +49 -366
  2. package/dist/chunks/Logger-CTAaDeZi.js.map +1 -0
  3. package/dist/chunks/Logger-D8pK7XXt.js +2 -0
  4. package/dist/chunks/Logger-D8pK7XXt.js.map +1 -0
  5. package/dist/chunks/ScopedLogger-D-7q8uVP.js +2 -0
  6. package/dist/chunks/ScopedLogger-D-7q8uVP.js.map +1 -0
  7. package/dist/chunks/ScopedLogger-hS0qSkZD.js +361 -0
  8. package/dist/chunks/ScopedLogger-hS0qSkZD.js.map +1 -0
  9. package/dist/core.js +280 -307
  10. package/dist/exports.cjs +1 -1
  11. package/dist/exports.js +1 -1
  12. package/dist/index.cjs +1 -1
  13. package/dist/index.cjs.map +1 -1
  14. package/dist/index.js +226 -159
  15. package/dist/index.js.map +1 -1
  16. package/dist/styling.cjs +1 -1
  17. package/dist/styling.js +2 -2
  18. package/dist/types/Logger.d.ts +17 -15
  19. package/dist/types/Logger.d.ts.map +1 -1
  20. package/dist/types/core.d.ts +122 -216
  21. package/dist/types/core.d.ts.map +1 -1
  22. package/dist/types/exports-module.d.ts +1 -1
  23. package/dist/types/exports-module.d.ts.map +1 -1
  24. package/dist/types/index.d.ts +119 -4
  25. package/dist/types/index.d.ts.map +1 -1
  26. package/dist/types/styling-module.d.ts +1 -1
  27. package/dist/types/styling-module.d.ts.map +1 -1
  28. package/package.json +2 -1
  29. package/src/Logger.ts +105 -58
  30. package/src/index.ts +32 -25
  31. package/dist/.tsbuildinfo +0 -1
  32. package/dist/Logger.d.ts +0 -710
  33. package/dist/Logger.d.ts.map +0 -1
  34. package/dist/Logger.js +0 -1118
  35. package/dist/ScopedLogger.d.ts +0 -318
  36. package/dist/ScopedLogger.d.ts.map +0 -1
  37. package/dist/ScopedLogger.js +0 -426
  38. package/dist/chunks/Logger-BW-kn5_7.js.map +0 -1
  39. package/dist/chunks/Logger-BpeuYIxR.js +0 -2
  40. package/dist/chunks/Logger-BpeuYIxR.js.map +0 -1
  41. package/dist/cli/CommandProcessor.d.ts +0 -103
  42. package/dist/cli/CommandProcessor.d.ts.map +0 -1
  43. package/dist/cli/CommandProcessor.js +0 -184
  44. package/dist/cli/commands/ConfigCommand.d.ts +0 -17
  45. package/dist/cli/commands/ConfigCommand.d.ts.map +0 -1
  46. package/dist/cli/commands/ConfigCommand.js +0 -88
  47. package/dist/cli/commands/ExportCommand.d.ts +0 -51
  48. package/dist/cli/commands/ExportCommand.d.ts.map +0 -1
  49. package/dist/cli/commands/ExportCommand.js +0 -243
  50. package/dist/cli/commands/HistoryCommand.d.ts +0 -50
  51. package/dist/cli/commands/HistoryCommand.d.ts.map +0 -1
  52. package/dist/cli/commands/HistoryCommand.js +0 -96
  53. package/dist/cli/commands/StatusCommand.d.ts +0 -33
  54. package/dist/cli/commands/StatusCommand.d.ts.map +0 -1
  55. package/dist/cli/commands/StatusCommand.js +0 -93
  56. package/dist/cli/commands/ThemeCommand.d.ts +0 -33
  57. package/dist/cli/commands/ThemeCommand.d.ts.map +0 -1
  58. package/dist/cli/commands/ThemeCommand.js +0 -79
  59. package/dist/cli/help.d.ts +0 -15
  60. package/dist/cli/help.d.ts.map +0 -1
  61. package/dist/cli/help.js +0 -118
  62. package/dist/cli/index.d.ts +0 -15
  63. package/dist/cli/index.d.ts.map +0 -1
  64. package/dist/cli/index.js +0 -46
  65. package/dist/constants.d.ts +0 -122
  66. package/dist/constants.d.ts.map +0 -1
  67. package/dist/constants.js +0 -159
  68. package/dist/core.d.ts +0 -134
  69. package/dist/core.d.ts.map +0 -1
  70. package/dist/example.d.ts +0 -18
  71. package/dist/example.d.ts.map +0 -1
  72. package/dist/example.js +0 -154
  73. package/dist/exports-module.d.ts +0 -203
  74. package/dist/exports-module.d.ts.map +0 -1
  75. package/dist/exports-module.js +0 -260
  76. package/dist/handlers/AnalyticsLogHandler.d.ts +0 -11
  77. package/dist/handlers/AnalyticsLogHandler.d.ts.map +0 -1
  78. package/dist/handlers/AnalyticsLogHandler.js +0 -19
  79. package/dist/handlers/ExportLogHandler.d.ts +0 -103
  80. package/dist/handlers/ExportLogHandler.d.ts.map +0 -1
  81. package/dist/handlers/ExportLogHandler.js +0 -516
  82. package/dist/handlers/FileLogHandler.d.ts +0 -36
  83. package/dist/handlers/FileLogHandler.d.ts.map +0 -1
  84. package/dist/handlers/FileLogHandler.js +0 -156
  85. package/dist/handlers/RemoteLogHandler.d.ts +0 -14
  86. package/dist/handlers/RemoteLogHandler.d.ts.map +0 -1
  87. package/dist/handlers/RemoteLogHandler.js +0 -37
  88. package/dist/handlers/index.d.ts +0 -8
  89. package/dist/handlers/index.d.ts.map +0 -1
  90. package/dist/handlers/index.js +0 -7
  91. package/dist/index.d.ts +0 -157
  92. package/dist/index.d.ts.map +0 -1
  93. package/dist/main.d.ts +0 -2
  94. package/dist/main.d.ts.map +0 -1
  95. package/dist/main.js +0 -139
  96. package/dist/styling/LogStyleBuilder.d.ts +0 -149
  97. package/dist/styling/LogStyleBuilder.d.ts.map +0 -1
  98. package/dist/styling/LogStyleBuilder.js +0 -289
  99. package/dist/styling/SemanticStyles.d.ts +0 -181
  100. package/dist/styling/SemanticStyles.d.ts.map +0 -1
  101. package/dist/styling/SemanticStyles.js +0 -339
  102. package/dist/styling/SmartPresets.d.ts +0 -25
  103. package/dist/styling/SmartPresets.d.ts.map +0 -1
  104. package/dist/styling/SmartPresets.js +0 -276
  105. package/dist/styling/StyleBuilder.d.ts +0 -140
  106. package/dist/styling/StyleBuilder.d.ts.map +0 -1
  107. package/dist/styling/StyleBuilder.js +0 -280
  108. package/dist/styling/banners.d.ts +0 -45
  109. package/dist/styling/banners.d.ts.map +0 -1
  110. package/dist/styling/banners.js +0 -155
  111. package/dist/styling/index.d.ts +0 -10
  112. package/dist/styling/index.d.ts.map +0 -1
  113. package/dist/styling/index.js +0 -9
  114. package/dist/styling/themes.d.ts +0 -10
  115. package/dist/styling/themes.d.ts.map +0 -1
  116. package/dist/styling/themes.js +0 -231
  117. package/dist/styling-module.d.ts +0 -185
  118. package/dist/styling-module.d.ts.map +0 -1
  119. package/dist/styling-module.js +0 -199
  120. package/dist/types/core.js +0 -28
  121. package/dist/types/handlers.d.ts +0 -88
  122. package/dist/types/handlers.d.ts.map +0 -1
  123. package/dist/types/handlers.js +0 -4
  124. package/dist/types/index.js +0 -4
  125. package/dist/utils/environment.d.ts +0 -47
  126. package/dist/utils/environment.d.ts.map +0 -1
  127. package/dist/utils/environment.js +0 -85
  128. package/dist/utils/formatting.d.ts +0 -40
  129. package/dist/utils/formatting.d.ts.map +0 -1
  130. package/dist/utils/formatting.js +0 -117
  131. package/dist/utils/index.d.ts +0 -7
  132. package/dist/utils/index.d.ts.map +0 -1
  133. package/dist/utils/index.js +0 -6
  134. package/dist/utils/opentui-detection.d.ts +0 -34
  135. package/dist/utils/opentui-detection.d.ts.map +0 -1
  136. package/dist/utils/opentui-detection.js +0 -116
  137. package/dist/utils/output.d.ts +0 -44
  138. package/dist/utils/output.d.ts.map +0 -1
  139. package/dist/utils/output.js +0 -150
  140. package/dist/utils/stackTrace.d.ts +0 -9
  141. package/dist/utils/stackTrace.d.ts.map +0 -1
  142. package/dist/utils/stackTrace.js +0 -81
  143. package/dist/utils/timestamps.d.ts +0 -20
  144. package/dist/utils/timestamps.d.ts.map +0 -1
  145. package/dist/utils/timestamps.js +0 -71
@@ -1,339 +0,0 @@
1
- /**
2
- * @fileoverview Semantic styling system for Advanced Logger
3
- */
4
- import { StyleBuilder } from './StyleBuilder.js';
5
- import { ADAPTIVE_COLORS } from '../constants.js';
6
- import { getAdaptiveColor } from '../utils/index.js';
7
- /**
8
- * Base semantic styler with common style methods
9
- */
10
- export class BaseStyler {
11
- builder;
12
- constructor(builder = new StyleBuilder()) {
13
- this.builder = builder;
14
- }
15
- /**
16
- * Primary brand color (typically blue)
17
- */
18
- primary() {
19
- return this.color('#007bff');
20
- }
21
- /**
22
- * Secondary color (typically gray)
23
- */
24
- secondary() {
25
- return this.color('#6c757d');
26
- }
27
- /**
28
- * Accent color for highlights
29
- */
30
- accent() {
31
- return this.color('#17a2b8');
32
- }
33
- /**
34
- * Muted/subtle color - automatically adaptive
35
- */
36
- muted() {
37
- const mutedColors = { light: '#6c757d', dark: '#a0aec0' };
38
- return this.color(getAdaptiveColor(mutedColors));
39
- }
40
- /**
41
- * Success color (green)
42
- */
43
- success() {
44
- return this.color('#28a745');
45
- }
46
- /**
47
- * Warning color (yellow/orange)
48
- */
49
- warning() {
50
- return this.color('#ffc107');
51
- }
52
- /**
53
- * Danger/error color (red)
54
- */
55
- danger() {
56
- return this.color('#dc3545');
57
- }
58
- /**
59
- * Monospace font family
60
- */
61
- mono() {
62
- this.builder.font('Monaco, Consolas, "Courier New", monospace');
63
- return this;
64
- }
65
- /**
66
- * System font family
67
- */
68
- system() {
69
- this.builder.font('system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif');
70
- return this;
71
- }
72
- /**
73
- * Readable font optimized for text
74
- */
75
- readable() {
76
- this.builder.font('Georgia, "Times New Roman", serif');
77
- return this;
78
- }
79
- /**
80
- * Compact spacing
81
- */
82
- compact() {
83
- this.builder.padding('1px 4px').margin('0 1px');
84
- return this;
85
- }
86
- /**
87
- * Spacious layout
88
- */
89
- spacious() {
90
- this.builder.padding('6px 12px').margin('2px 4px');
91
- return this;
92
- }
93
- /**
94
- * Inline display
95
- */
96
- inline() {
97
- this.builder.display('inline-block');
98
- return this;
99
- }
100
- /**
101
- * Glass morphism effect
102
- */
103
- glassmorphic() {
104
- this.builder
105
- .css('backdrop-filter', 'blur(10px)')
106
- .css('background', 'rgba(255, 255, 255, 0.1)')
107
- .border('1px solid rgba(255, 255, 255, 0.2)')
108
- .rounded('8px');
109
- return this;
110
- }
111
- /**
112
- * Neon glow effect
113
- */
114
- neon() {
115
- const neonColor = '#00ffff';
116
- this.builder
117
- .color(neonColor)
118
- .border(`1px solid ${neonColor}`)
119
- .shadow(`0 0 10px ${neonColor}, 0 0 20px ${neonColor}`)
120
- .css('text-shadow', `0 0 5px ${neonColor}`);
121
- return this;
122
- }
123
- /**
124
- * Gradient background
125
- */
126
- gradient(from = '#667eea', to = '#764ba2') {
127
- this.builder.bg(`linear-gradient(135deg, ${from} 0%, ${to} 100%)`);
128
- return this;
129
- }
130
- /**
131
- * Bold text
132
- */
133
- bold() {
134
- this.builder.bold();
135
- return this;
136
- }
137
- /**
138
- * Set color with automatic adaptation
139
- */
140
- color(color) {
141
- this.builder.color(color);
142
- return this;
143
- }
144
- /**
145
- * Build the final CSS string
146
- */
147
- build() {
148
- return this.builder.build();
149
- }
150
- }
151
- /**
152
- * Timestamp-specific styling
153
- */
154
- export class TimestampStyler extends BaseStyler {
155
- /**
156
- * Default timestamp style - subtle and informative
157
- */
158
- default() {
159
- this.muted().mono();
160
- this.builder.size('11px');
161
- return this;
162
- }
163
- /**
164
- * Hide timestamp
165
- */
166
- hidden() {
167
- this.builder.display('none');
168
- return this;
169
- }
170
- /**
171
- * Minimal timestamp (just time, no date)
172
- */
173
- minimal() {
174
- this.muted().mono();
175
- this.builder.size('10px').opacity(0.7);
176
- return this;
177
- }
178
- /**
179
- * Set font size
180
- */
181
- size(size) {
182
- this.builder.size(size);
183
- return this;
184
- }
185
- }
186
- /**
187
- * Level badge styling
188
- */
189
- export class LevelStyler extends BaseStyler {
190
- /**
191
- * Colorful gradient badge
192
- */
193
- badge() {
194
- this.builder
195
- .padding('2px 8px')
196
- .rounded('4px')
197
- .bold()
198
- .color('#ffffff');
199
- return this;
200
- }
201
- /**
202
- * Glowing effect for dark themes
203
- */
204
- glowing() {
205
- return this.neon().badge();
206
- }
207
- /**
208
- * Minimal flat style
209
- */
210
- flat() {
211
- this.builder
212
- .padding('1px 6px')
213
- .rounded('2px')
214
- .border('1px solid currentColor')
215
- .css('background', 'transparent');
216
- return this;
217
- }
218
- /**
219
- * Uppercase text
220
- */
221
- uppercase() {
222
- this.builder.uppercase();
223
- return this;
224
- }
225
- }
226
- /**
227
- * Prefix styling
228
- */
229
- export class PrefixStyler extends BaseStyler {
230
- /**
231
- * Dark theme prefix
232
- */
233
- dark() {
234
- const prefixColors = { light: '#2d3748', dark: '#4a5568' };
235
- const textColors = { light: '#e2e8f0', dark: '#f7fafc' };
236
- this.builder
237
- .bg(getAdaptiveColor(prefixColors))
238
- .color(getAdaptiveColor(textColors))
239
- .padding('2px 6px')
240
- .rounded('3px')
241
- .bold()
242
- .mono()
243
- .size('11px');
244
- return this;
245
- }
246
- /**
247
- * Light theme prefix
248
- */
249
- light() {
250
- this.builder
251
- .bg('#f8f9fa')
252
- .color('#495057')
253
- .padding('2px 6px')
254
- .rounded('3px')
255
- .bold()
256
- .mono()
257
- .size('11px')
258
- .border('1px solid #dee2e6');
259
- return this;
260
- }
261
- /**
262
- * Compact prefix
263
- */
264
- compact() {
265
- this.builder
266
- .padding('1px 4px')
267
- .size('10px')
268
- .rounded('2px');
269
- return this;
270
- }
271
- }
272
- /**
273
- * Message text styling
274
- */
275
- export class MessageStyler extends BaseStyler {
276
- /**
277
- * Readable message text - automatically adaptive
278
- */
279
- readable() {
280
- this.builder
281
- .color(getAdaptiveColor(ADAPTIVE_COLORS.messageText))
282
- .system()
283
- .size('14px');
284
- return this;
285
- }
286
- /**
287
- * Code-style monospace text
288
- */
289
- code() {
290
- this.builder
291
- .mono()
292
- .size('13px')
293
- .color(getAdaptiveColor(ADAPTIVE_COLORS.messageText))
294
- .bg('rgba(0, 0, 0, 0.05)')
295
- .padding('1px 4px')
296
- .rounded('3px');
297
- return this;
298
- }
299
- /**
300
- * Large, prominent text
301
- */
302
- large() {
303
- this.builder
304
- .size('16px')
305
- .color(getAdaptiveColor(ADAPTIVE_COLORS.messageText));
306
- return this;
307
- }
308
- }
309
- /**
310
- * Location info styling
311
- */
312
- export class LocationStyler extends BaseStyler {
313
- /**
314
- * Subtle location info - automatically adaptive
315
- */
316
- subtle() {
317
- this.builder
318
- .color(getAdaptiveColor(ADAPTIVE_COLORS.location))
319
- .mono()
320
- .size('11px')
321
- .opacity(0.7);
322
- return this;
323
- }
324
- /**
325
- * Hide location info
326
- */
327
- hidden() {
328
- this.builder.display('none');
329
- return this;
330
- }
331
- /**
332
- * Clickable style (for IDE integration)
333
- */
334
- clickable() {
335
- this.subtle();
336
- this.builder.css('text-decoration', 'underline').cursor('pointer');
337
- return this;
338
- }
339
- }
@@ -1,25 +0,0 @@
1
- /**
2
- * @fileoverview Smart presets for simplified logger configuration
3
- */
4
- import type { LogStyles } from '../types/index.js';
5
- /**
6
- * Smart presets that configure the entire log appearance
7
- */
8
- export declare const SMART_PRESETS: Record<string, LogStyles>;
9
- /**
10
- * Get a smart preset by name
11
- */
12
- export declare function getSmartPreset(name: string): LogStyles | null;
13
- /**
14
- * List all available smart presets
15
- */
16
- export declare function getAvailablePresets(): string[];
17
- /**
18
- * Check if a preset exists
19
- */
20
- export declare function hasPreset(name: string): boolean;
21
- /**
22
- * Preset descriptions for help/documentation
23
- */
24
- export declare const PRESET_DESCRIPTIONS: Record<string, string>;
25
- //# sourceMappingURL=SmartPresets.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"SmartPresets.d.ts","sourceRoot":"","sources":["../../src/styling/SmartPresets.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,KAAK,EAAE,SAAS,EAAa,MAAM,mBAAmB,CAAC;AAE9D;;GAEG;AACH,eAAO,MAAM,aAAa,EAAE,MAAM,CAAC,MAAM,EAAE,SAAS,CAqPnD,CAAC;AAEF;;GAEG;AACH,wBAAgB,cAAc,CAAC,IAAI,EAAE,MAAM,GAAG,SAAS,GAAG,IAAI,CAE7D;AAED;;GAEG;AACH,wBAAgB,mBAAmB,IAAI,MAAM,EAAE,CAE9C;AAED;;GAEG;AACH,wBAAgB,SAAS,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAE/C;AAED;;GAEG;AACH,eAAO,MAAM,mBAAmB,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAOtD,CAAC"}
@@ -1,276 +0,0 @@
1
- /**
2
- * @fileoverview Smart presets for simplified logger configuration
3
- */
4
- /**
5
- * Smart presets that configure the entire log appearance
6
- */
7
- export const SMART_PRESETS = {
8
- /**
9
- * Default preset - works perfectly out-of-the-box
10
- * Clean, readable, automatically adaptive to dark/light themes
11
- */
12
- default: {
13
- layout: {
14
- spacing: 'normal',
15
- innerPadding: '2px',
16
- outerMargin: '1px'
17
- },
18
- timestamp: {
19
- show: true,
20
- color: 'auto', // Automatically adaptive
21
- font: 'Monaco, Consolas, monospace',
22
- size: '11px'
23
- },
24
- level: {
25
- show: true,
26
- style: 'badge',
27
- uppercase: false,
28
- padding: '2px 8px'
29
- },
30
- prefix: {
31
- show: true,
32
- style: 'dark', // Automatically adaptive
33
- padding: '2px 6px'
34
- },
35
- message: {
36
- show: true,
37
- color: 'auto', // Automatically adaptive
38
- font: 'system-ui, -apple-system, sans-serif',
39
- size: '14px'
40
- },
41
- location: {
42
- show: true,
43
- color: 'auto', // Automatically adaptive
44
- font: 'Monaco, Consolas, monospace',
45
- size: '11px'
46
- }
47
- },
48
- /**
49
- * Cyberpunk preset - neon colors, glowing effects, dark theme
50
- */
51
- cyberpunk: {
52
- layout: {
53
- spacing: 'compact',
54
- innerPadding: '1px',
55
- outerMargin: '0px'
56
- },
57
- timestamp: {
58
- show: true,
59
- color: '#00ffff',
60
- font: 'Monaco, Consolas, monospace',
61
- size: '10px',
62
- style: 'neon'
63
- },
64
- level: {
65
- show: true,
66
- style: 'glowing',
67
- uppercase: true,
68
- padding: '2px 8px'
69
- },
70
- prefix: {
71
- show: true,
72
- color: '#ff0080',
73
- background: 'rgba(255, 0, 128, 0.1)',
74
- border: '1px solid #ff0080',
75
- style: 'neon'
76
- },
77
- message: {
78
- show: true,
79
- color: '#00ff41',
80
- font: 'Monaco, Consolas, monospace',
81
- size: '13px'
82
- },
83
- location: {
84
- show: false // Hidden for cleaner look
85
- },
86
- backdrop: 'blur(2px)',
87
- transparency: 0.9
88
- },
89
- /**
90
- * Glassmorphism preset - modern blur effects, transparency
91
- */
92
- glassmorphism: {
93
- layout: {
94
- spacing: 'spacious',
95
- innerPadding: '4px',
96
- outerMargin: '2px'
97
- },
98
- timestamp: {
99
- show: true,
100
- color: 'auto',
101
- font: 'system-ui, sans-serif',
102
- size: '11px',
103
- style: 'glassmorphic'
104
- },
105
- level: {
106
- show: true,
107
- style: 'glassmorphic',
108
- uppercase: false,
109
- padding: '4px 12px'
110
- },
111
- prefix: {
112
- show: true,
113
- style: 'glassmorphic',
114
- padding: '3px 8px'
115
- },
116
- message: {
117
- show: true,
118
- color: 'auto',
119
- font: 'system-ui, sans-serif',
120
- size: '14px'
121
- },
122
- location: {
123
- show: true,
124
- color: 'auto',
125
- font: 'system-ui, sans-serif',
126
- size: '11px',
127
- style: 'glassmorphic'
128
- },
129
- backdrop: 'blur(10px)',
130
- transparency: 0.8
131
- },
132
- /**
133
- * Minimal preset - clean, no decorations, maximum readability
134
- */
135
- minimal: {
136
- layout: {
137
- spacing: 'compact',
138
- innerPadding: '0px',
139
- outerMargin: '0px'
140
- },
141
- timestamp: {
142
- show: false // Hidden for minimal look
143
- },
144
- level: {
145
- show: true,
146
- style: 'flat',
147
- uppercase: true,
148
- padding: '0px 4px',
149
- border: 'none',
150
- background: 'transparent'
151
- },
152
- prefix: {
153
- show: true,
154
- style: 'flat',
155
- padding: '0px 4px',
156
- border: 'none',
157
- background: 'transparent'
158
- },
159
- message: {
160
- show: true,
161
- color: 'auto',
162
- font: 'system-ui, sans-serif',
163
- size: '14px'
164
- },
165
- location: {
166
- show: false // Hidden for minimal look
167
- }
168
- },
169
- /**
170
- * Debug preset - monospace, detailed, compact for development
171
- */
172
- debug: {
173
- layout: {
174
- spacing: 'compact',
175
- innerPadding: '1px',
176
- outerMargin: '0px'
177
- },
178
- timestamp: {
179
- show: true,
180
- color: 'auto',
181
- font: 'Monaco, Consolas, monospace',
182
- size: '10px'
183
- },
184
- level: {
185
- show: true,
186
- style: 'compact',
187
- uppercase: true,
188
- padding: '1px 4px',
189
- font: 'Monaco, Consolas, monospace',
190
- size: '10px'
191
- },
192
- prefix: {
193
- show: true,
194
- style: 'compact',
195
- padding: '1px 4px',
196
- font: 'Monaco, Consolas, monospace',
197
- size: '10px'
198
- },
199
- message: {
200
- show: true,
201
- color: 'auto',
202
- font: 'Monaco, Consolas, monospace',
203
- size: '12px'
204
- },
205
- location: {
206
- show: true,
207
- color: 'auto',
208
- font: 'Monaco, Consolas, monospace',
209
- size: '10px',
210
- style: 'clickable'
211
- }
212
- },
213
- /**
214
- * Production preset - clean, essential info only
215
- */
216
- production: {
217
- layout: {
218
- spacing: 'normal',
219
- innerPadding: '2px',
220
- outerMargin: '1px'
221
- },
222
- timestamp: {
223
- show: true,
224
- color: 'auto',
225
- font: 'system-ui, sans-serif',
226
- size: '11px'
227
- },
228
- level: {
229
- show: true,
230
- style: 'badge',
231
- uppercase: false,
232
- padding: '2px 6px'
233
- },
234
- prefix: {
235
- show: false // Hidden in production
236
- },
237
- message: {
238
- show: true,
239
- color: 'auto',
240
- font: 'system-ui, sans-serif',
241
- size: '14px'
242
- },
243
- location: {
244
- show: false // Hidden in production
245
- }
246
- }
247
- };
248
- /**
249
- * Get a smart preset by name
250
- */
251
- export function getSmartPreset(name) {
252
- return SMART_PRESETS[name] || null;
253
- }
254
- /**
255
- * List all available smart presets
256
- */
257
- export function getAvailablePresets() {
258
- return Object.keys(SMART_PRESETS);
259
- }
260
- /**
261
- * Check if a preset exists
262
- */
263
- export function hasPreset(name) {
264
- return name in SMART_PRESETS;
265
- }
266
- /**
267
- * Preset descriptions for help/documentation
268
- */
269
- export const PRESET_DESCRIPTIONS = {
270
- default: 'Clean, readable, automatically adaptive to dark/light themes',
271
- cyberpunk: 'Neon colors, glowing effects, perfect for dark themes',
272
- glassmorphism: 'Modern blur effects with transparency and spacious layout',
273
- minimal: 'Clean and simple, no decorations, maximum readability',
274
- debug: 'Monospace fonts, detailed info, compact layout for development',
275
- production: 'Professional look with essential information only'
276
- };