@omnitron-dev/prism 0.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (83) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +44 -0
  3. package/bin/prism.js +13 -0
  4. package/dist/accessibility/index.d.ts +157 -0
  5. package/dist/accessibility/index.js +186 -0
  6. package/dist/accessibility/index.js.map +1 -0
  7. package/dist/blocks/index.d.ts +1239 -0
  8. package/dist/blocks/index.js +1712 -0
  9. package/dist/blocks/index.js.map +1 -0
  10. package/dist/chunk-77KIJLPP.js +37 -0
  11. package/dist/chunk-77KIJLPP.js.map +1 -0
  12. package/dist/chunk-BTIT7WYH.js +339 -0
  13. package/dist/chunk-BTIT7WYH.js.map +1 -0
  14. package/dist/chunk-BV32OJ2A.js +1409 -0
  15. package/dist/chunk-BV32OJ2A.js.map +1 -0
  16. package/dist/chunk-DDY7TLUI.js +139 -0
  17. package/dist/chunk-DDY7TLUI.js.map +1 -0
  18. package/dist/chunk-DXXZ3ITR.js +4227 -0
  19. package/dist/chunk-DXXZ3ITR.js.map +1 -0
  20. package/dist/chunk-E3XANPTO.js +2319 -0
  21. package/dist/chunk-E3XANPTO.js.map +1 -0
  22. package/dist/chunk-FU52GL2E.js +3 -0
  23. package/dist/chunk-FU52GL2E.js.map +1 -0
  24. package/dist/chunk-GYDT5EKX.js +16505 -0
  25. package/dist/chunk-GYDT5EKX.js.map +1 -0
  26. package/dist/chunk-HO2GKTWJ.js +28 -0
  27. package/dist/chunk-HO2GKTWJ.js.map +1 -0
  28. package/dist/chunk-JDTC2SBY.js +140 -0
  29. package/dist/chunk-JDTC2SBY.js.map +1 -0
  30. package/dist/chunk-JNU4QHJK.js +6 -0
  31. package/dist/chunk-JNU4QHJK.js.map +1 -0
  32. package/dist/chunk-LAEY5USO.js +2621 -0
  33. package/dist/chunk-LAEY5USO.js.map +1 -0
  34. package/dist/chunk-UR6X3W5I.js +530 -0
  35. package/dist/chunk-UR6X3W5I.js.map +1 -0
  36. package/dist/chunk-WC2WM2JD.js +883 -0
  37. package/dist/chunk-WC2WM2JD.js.map +1 -0
  38. package/dist/chunk-XWL6J6IO.js +40 -0
  39. package/dist/chunk-XWL6J6IO.js.map +1 -0
  40. package/dist/cli/index.js +2695 -0
  41. package/dist/cli/index.js.map +1 -0
  42. package/dist/config-BA6IeTq9.d.ts +100 -0
  43. package/dist/core/index.d.ts +454 -0
  44. package/dist/core/index.js +9 -0
  45. package/dist/core/index.js.map +1 -0
  46. package/dist/forms/index.d.ts +562 -0
  47. package/dist/forms/index.js +545 -0
  48. package/dist/forms/index.js.map +1 -0
  49. package/dist/hooks/index.d.ts +7 -0
  50. package/dist/hooks/index.js +10 -0
  51. package/dist/hooks/index.js.map +1 -0
  52. package/dist/http/index.d.ts +233 -0
  53. package/dist/http/index.js +282 -0
  54. package/dist/http/index.js.map +1 -0
  55. package/dist/index-odhPSv9I.d.ts +2491 -0
  56. package/dist/index.css +131 -0
  57. package/dist/index.css.map +1 -0
  58. package/dist/index.d.ts +9109 -0
  59. package/dist/index.js +13280 -0
  60. package/dist/index.js.map +1 -0
  61. package/dist/layouts/index.d.ts +854 -0
  62. package/dist/layouts/index.js +6 -0
  63. package/dist/layouts/index.js.map +1 -0
  64. package/dist/netron/index.d.ts +4 -0
  65. package/dist/netron/index.js +4 -0
  66. package/dist/netron/index.js.map +1 -0
  67. package/dist/registry/index.d.ts +352 -0
  68. package/dist/registry/index.js +4 -0
  69. package/dist/registry/index.js.map +1 -0
  70. package/dist/registry-BrDNftd5.d.ts +574 -0
  71. package/dist/settings-plpR26Xk.d.ts +455 -0
  72. package/dist/state/index.d.ts +981 -0
  73. package/dist/state/index.js +5 -0
  74. package/dist/state/index.js.map +1 -0
  75. package/dist/theme/index.d.ts +1049 -0
  76. package/dist/theme/index.js +5 -0
  77. package/dist/theme/index.js.map +1 -0
  78. package/dist/theme-CrXLfP1c.d.ts +389 -0
  79. package/dist/types/index.d.ts +146 -0
  80. package/dist/types/index.js +5 -0
  81. package/dist/types/index.js.map +1 -0
  82. package/dist/use-timeout-D7U3EAtH.d.ts +808 -0
  83. package/package.json +194 -0
@@ -0,0 +1,1049 @@
1
+ import * as locales from '@mui/material/locale';
2
+ import { ThemeOptions, PaletteOptions, Shadows, Theme, CSSObject, Components } from '@mui/material/styles';
3
+ import { f as ColorGroup, b as ThemePreset, a as ThemeMode, c as ThemeDirection, C as ComponentDensity, l as CssVariablesConfig, k as ComponentsConfig, o as PrismTheme, g as ColorScale, e as ChartPalette, m as PaletteColorWithChannels, V as VibrantPalette, r as ThemePalette, P as PaletteColor, h as ColorScaleWithChannels, s as ThemeTypography, d as ThemePresetDefinition } from '../theme-CrXLfP1c.js';
4
+ export { B as BackgroundPalette, i as ColorShadeKey } from '../theme-CrXLfP1c.js';
5
+ import { Components as Components$1, Theme as Theme$1 } from '@mui/material';
6
+
7
+ /**
8
+ * Theme Factory
9
+ *
10
+ * Creates MUI themes with full Prism integration.
11
+ * Uses MUI's native colorSchemes for automatic light/dark mode.
12
+ *
13
+ * Key Features:
14
+ * - Native MUI colorSchemes integration (automatic dark/light switching)
15
+ * - CSS variables with configurable prefix and `theme.vars.palette.*` access
16
+ * - Density-based component sizing (compact/standard/comfortable)
17
+ * - Runtime primary color override system
18
+ * - Full TypeScript inference
19
+ * - Tree-shakeable component overrides
20
+ *
21
+ * @module @omnitron-dev/prism/theme/create-theme
22
+ */
23
+
24
+ type SupportedLocale = keyof typeof locales;
25
+ /**
26
+ * Options for creating a Prism theme.
27
+ *
28
+ * @example
29
+ * ```tsx
30
+ * // Minimal configuration
31
+ * const theme = createPrismTheme();
32
+ *
33
+ * // Full configuration
34
+ * const theme = createPrismTheme({
35
+ * preset: 'luxury',
36
+ * mode: 'dark',
37
+ * primaryColor: '#FF5630',
38
+ * density: 'compact',
39
+ * locale: 'ruRU',
40
+ * direction: 'ltr',
41
+ * cssVarPrefix: 'myapp',
42
+ * borderRadius: 12,
43
+ * responsiveFonts: true,
44
+ * });
45
+ * ```
46
+ */
47
+ interface CreatePrismThemeOptions {
48
+ /** Theme preset (default: 'default-light') */
49
+ preset?: ThemePreset;
50
+ /** Light/dark/system mode (default: 'light') */
51
+ mode?: ThemeMode;
52
+ /** Text direction (default: 'ltr') */
53
+ direction?: ThemeDirection;
54
+ /** MUI locale for i18n (default: 'enUS') */
55
+ locale?: SupportedLocale;
56
+ /** Custom primary color override (hex, e.g., '#FF5630') */
57
+ primaryColor?: string | null;
58
+ /** CSS variable prefix (default: 'prism') */
59
+ cssVarPrefix?: string;
60
+ /** Component density (default: 'standard') */
61
+ density?: ComponentDensity;
62
+ /** Border radius in pixels (default: 8) */
63
+ borderRadius?: number;
64
+ /** Enable responsive font sizes (default: true) */
65
+ responsiveFonts?: boolean;
66
+ /** Custom MUI theme overrides */
67
+ overrides?: Partial<ThemeOptions>;
68
+ /** Typography configuration (optional override) */
69
+ typography?: Partial<ThemeOptions['typography']>;
70
+ /** CSS variables configuration (optional override) */
71
+ cssVariables?: Partial<CssVariablesConfig>;
72
+ /** Components configuration (optional override) */
73
+ components?: Partial<ComponentsConfig>;
74
+ /** Contrast mode: 'default' or 'high' (default: 'default') */
75
+ contrast?: 'default' | 'high';
76
+ /** Override primary font family */
77
+ fontFamily?: string | null;
78
+ /** Override base font size in px (12-20, default: 16) */
79
+ fontSize?: number;
80
+ }
81
+ /**
82
+ * Available color groups for primary color override.
83
+ * When primaryColor matches a group's main color, we use that group's full palette
84
+ * for proper shade generation in both light and dark modes.
85
+ */
86
+ declare const COLOR_GROUPS: ColorGroup[];
87
+ /**
88
+ * Create a Prism theme.
89
+ *
90
+ * This is the main entry point for creating themes. It uses MUI's native
91
+ * colorSchemes for automatic light/dark mode switching, CSS variables
92
+ * for dynamic theming, and includes all Prism extensions.
93
+ *
94
+ * @example
95
+ * ```tsx
96
+ * // Basic usage
97
+ * const theme = createPrismTheme({ preset: 'luxury', mode: 'dark' });
98
+ *
99
+ * // With custom primary color
100
+ * const theme = createPrismTheme({
101
+ * preset: 'default-light',
102
+ * primaryColor: '#FF5630',
103
+ * density: 'compact',
104
+ * });
105
+ *
106
+ * // Use with MUI ThemeProvider
107
+ * <ThemeProvider theme={theme}>
108
+ * <App />
109
+ * </ThemeProvider>
110
+ * ```
111
+ *
112
+ * @param options - Theme creation options
113
+ * @returns MUI theme with Prism extensions
114
+ */
115
+ declare function createPrismTheme(options?: CreatePrismThemeOptions): PrismTheme;
116
+ /**
117
+ * Available preset names.
118
+ */
119
+ declare const PRESET_NAMES: readonly ThemePreset[];
120
+ /**
121
+ * Preset display names for UI.
122
+ */
123
+ declare const PRESET_DISPLAY_NAMES: Record<ThemePreset, string>;
124
+ /**
125
+ * Inherent mode for each preset.
126
+ * Non-default presets are inherently light or dark — selecting them forces the mode.
127
+ * Default presets respect the user's light/dark/system toggle.
128
+ */
129
+ declare const PRESET_INHERENT_MODE: Record<ThemePreset, 'light' | 'dark'>;
130
+ /**
131
+ * Get preset display name.
132
+ */
133
+ declare function getPresetDisplayName(preset: ThemePreset): string;
134
+
135
+ /**
136
+ * Palette Builder
137
+ *
138
+ * Creates MUI-native palette structures with full channel support.
139
+ * Designed for maximum integration with MUI's colorSchemes and CSS variables.
140
+ *
141
+ * Key MUI Integration Points:
142
+ * - Uses MUI's PaletteOptions structure directly
143
+ * - Generates channel values for use with `theme.vars.palette.*.mainChannel`
144
+ * - Supports MUI's `applyStyles` for dark mode variants
145
+ * - Works seamlessly with MUI's CSS variable system
146
+ *
147
+ * @module @omnitron-dev/prism/theme/palette/builder
148
+ */
149
+
150
+ /**
151
+ * Build palette color from color scale.
152
+ *
153
+ * @param scale - 11-shade color scale
154
+ * @param mode - Light or dark mode
155
+ * @returns Palette color with channels
156
+ */
157
+ declare function buildPaletteColor(scale: ColorScale, mode?: 'light' | 'dark'): PaletteColorWithChannels;
158
+ interface BackgroundColors {
159
+ default: string;
160
+ paper: string;
161
+ neutral: string;
162
+ elevation1: string;
163
+ elevation2: string;
164
+ elevation3: string;
165
+ elevation4: string;
166
+ menu: string;
167
+ menuElevation1: string;
168
+ menuElevation2: string;
169
+ }
170
+ /**
171
+ * Build background palette from grey scale.
172
+ *
173
+ * @param grey - Grey color scale
174
+ * @param mode - Light or dark mode
175
+ * @returns Background colors
176
+ */
177
+ declare function buildBackground(grey: ColorScale, mode?: 'light' | 'dark'): BackgroundColors;
178
+ interface TextColors {
179
+ primary: string;
180
+ secondary: string;
181
+ disabled: string;
182
+ primaryChannel: string;
183
+ secondaryChannel: string;
184
+ disabledChannel: string;
185
+ }
186
+ /**
187
+ * Build text colors from grey scale.
188
+ *
189
+ * @param grey - Grey color scale
190
+ * @param mode - Light or dark mode
191
+ * @returns Text colors with channels
192
+ */
193
+ declare function buildText(grey: ColorScale, mode?: 'light' | 'dark'): TextColors;
194
+ interface ActionColors {
195
+ active: string;
196
+ hover: string;
197
+ selected: string;
198
+ disabled: string;
199
+ disabledBackground: string;
200
+ focus: string;
201
+ }
202
+ /**
203
+ * Build action colors from grey scale.
204
+ *
205
+ * @param grey - Grey color scale
206
+ * @param mode - Light or dark mode
207
+ * @returns Action colors
208
+ */
209
+ declare function buildAction(grey: ColorScale, mode?: 'light' | 'dark'): ActionColors;
210
+ /**
211
+ * Build vibrant colors for overlays and glass effects.
212
+ *
213
+ * @param commonWhiteChannel - White color channel
214
+ * @param textPrimary - Primary text color
215
+ * @param mode - Light or dark mode
216
+ * @returns Vibrant palette
217
+ */
218
+ declare function buildVibrant(commonWhiteChannel: string, textPrimary: string, mode?: 'light' | 'dark'): VibrantPalette;
219
+ /**
220
+ * Build chart color palette.
221
+ *
222
+ * @param options - Color scales for charts
223
+ * @returns Chart palette
224
+ */
225
+ declare function buildChartColors(options: {
226
+ grey: ColorScale;
227
+ red: ColorScale;
228
+ blue: ColorScale;
229
+ green: ColorScale;
230
+ orange: ColorScale;
231
+ lightBlue: ColorScale;
232
+ purple: ColorScale;
233
+ }): ChartPalette;
234
+ interface BuildPaletteOptions {
235
+ /** Primary color scale */
236
+ primary: ColorScale;
237
+ /** Secondary color scale */
238
+ secondary: ColorScale;
239
+ /** Info color scale */
240
+ info: ColorScale;
241
+ /** Success color scale */
242
+ success: ColorScale;
243
+ /** Warning color scale */
244
+ warning: ColorScale;
245
+ /** Error color scale */
246
+ error: ColorScale;
247
+ /** Neutral/grey color scale */
248
+ grey: ColorScale;
249
+ /** Light or dark mode */
250
+ mode: 'light' | 'dark';
251
+ /** Custom background default color */
252
+ backgroundDefault?: string;
253
+ /** Custom paper color */
254
+ paperColor?: string;
255
+ }
256
+ /**
257
+ * Build complete MUI-compatible palette.
258
+ *
259
+ * @param options - Palette build options
260
+ * @returns Complete MUI palette options
261
+ */
262
+ declare function buildPalette(options: BuildPaletteOptions): PaletteOptions;
263
+ /**
264
+ * Default light palette.
265
+ */
266
+ declare const defaultLightPalette: PaletteOptions;
267
+ /**
268
+ * Default dark palette.
269
+ */
270
+ declare const defaultDarkPalette: PaletteOptions;
271
+
272
+ /**
273
+ * Palette Utilities
274
+ *
275
+ * Utilities for palette manipulation and CSS channel generation.
276
+ * All color math uses HSL for perceptually correct results.
277
+ *
278
+ * @module @omnitron-dev/prism/theme/palette
279
+ */
280
+
281
+ /**
282
+ * Generate RGB channel string from hex color.
283
+ *
284
+ * @param hex - Hex color value
285
+ * @returns RGB channel string (e.g., "255 255 255")
286
+ */
287
+ declare function generatePaletteChannel(hex: string): string;
288
+ /**
289
+ * Apply primary color override to a palette.
290
+ *
291
+ * @param palette - Base palette
292
+ * @param primaryColor - New primary color
293
+ * @param mode - Theme mode (light/dark)
294
+ * @returns Updated palette with new primary color
295
+ */
296
+ declare function applyPrimaryOverride(palette: ThemePalette, primaryColor: string, mode?: 'light' | 'dark'): ThemePalette;
297
+
298
+ /**
299
+ * Color Utilities
300
+ *
301
+ * Functions for color manipulation, channel generation, and palette creation.
302
+ * Uses HSL-based color math for perceptually correct results.
303
+ * Combines Aurora's sophisticated color system with Prism's extensibility.
304
+ *
305
+ * @module @omnitron-dev/prism/theme/utils/color
306
+ */
307
+
308
+ /**
309
+ * Convert hex color to RGB values.
310
+ *
311
+ * @param hex - Hex color string (e.g., '#FF5630' or 'FF5630')
312
+ * @returns RGB tuple [r, g, b]
313
+ */
314
+ declare function hexToRgb(hex: string): [number, number, number];
315
+ /**
316
+ * Convert hex color to RGB channel string.
317
+ *
318
+ * @param hex - Hex color string
319
+ * @returns RGB channel string (e.g., '255 86 48')
320
+ */
321
+ declare function hexToRgbChannel(hex: string): string;
322
+ /**
323
+ * Convert RGB values to hex color.
324
+ *
325
+ * @param r - Red (0-255)
326
+ * @param g - Green (0-255)
327
+ * @param b - Blue (0-255)
328
+ * @returns Hex color string (e.g., '#FF5630')
329
+ */
330
+ declare function rgbToHex(r: number, g: number, b: number): string;
331
+ /**
332
+ * Convert hex to HSL values.
333
+ *
334
+ * @param hex - Hex color string
335
+ * @returns HSL values { h: 0-360, s: 0-100, l: 0-100 }
336
+ */
337
+ declare function hexToHsl(hex: string): {
338
+ h: number;
339
+ s: number;
340
+ l: number;
341
+ };
342
+ /**
343
+ * Convert HSL values to hex color.
344
+ *
345
+ * @param h - Hue (0-360)
346
+ * @param s - Saturation (0-100)
347
+ * @param l - Lightness (0-100)
348
+ * @returns Hex color string
349
+ */
350
+ declare function hslToHex(h: number, s: number, l: number): string;
351
+ /**
352
+ * Create CSS rgba() from hex color.
353
+ *
354
+ * @param color - Hex color string
355
+ * @param alpha - Alpha value (0-1)
356
+ * @returns CSS rgba string
357
+ */
358
+ declare function rgba(color: string, alpha: number): string;
359
+ /**
360
+ * Create CSS rgba() from RGB channel string.
361
+ * Useful for CSS variable references.
362
+ *
363
+ * @param channel - RGB channel string (e.g., '255 86 48')
364
+ * @param alpha - Alpha value (0-1)
365
+ * @returns CSS rgba string using modern syntax
366
+ */
367
+ declare function cssVarRgba(channel: string, alpha: number): string;
368
+ /**
369
+ * Generate palette color with channel values.
370
+ *
371
+ * @param color - Palette color object
372
+ * @returns Palette color with channel values
373
+ */
374
+ declare function generatePaletteColorWithChannels(color: PaletteColor): PaletteColorWithChannels;
375
+ /**
376
+ * Generate color scale with channel values.
377
+ *
378
+ * @param scale - Color scale object
379
+ * @returns Color scale with channel values
380
+ */
381
+ declare function generateColorScaleWithChannels(scale: ColorScale): ColorScaleWithChannels;
382
+ /**
383
+ * Generate 11-shade color scale from a base color.
384
+ * Uses HSL manipulation to create consistent, accessible shades.
385
+ *
386
+ * @param baseColor - Base hex color (typically the 500 shade)
387
+ * @returns Full 11-shade color scale
388
+ */
389
+ declare function generateColorScale(baseColor: string): ColorScale;
390
+ /**
391
+ * Create semantic palette color from a color scale.
392
+ * Maps 11-shade scale to 5-shade semantic naming.
393
+ *
394
+ * @param scale - Full color scale
395
+ * @param mode - Light or dark mode
396
+ * @returns Semantic palette color
397
+ */
398
+ declare function createPaletteColorFromScale(scale: ColorScale, mode?: 'light' | 'dark'): PaletteColor;
399
+ /**
400
+ * Create inverted color scale for dark mode.
401
+ * Swaps light and dark shades for proper dark mode contrast.
402
+ *
403
+ * @param scale - Original color scale
404
+ * @returns Inverted color scale
405
+ */
406
+ declare function invertColorScale(scale: ColorScale): ColorScale;
407
+ /**
408
+ * Calculate relative luminance of a color.
409
+ *
410
+ * @param hex - Hex color string
411
+ * @returns Relative luminance (0-1)
412
+ */
413
+ declare function getLuminance(hex: string): number;
414
+ /**
415
+ * Calculate contrast ratio between two colors.
416
+ *
417
+ * @param color1 - First hex color
418
+ * @param color2 - Second hex color
419
+ * @returns Contrast ratio (1-21)
420
+ */
421
+ declare function getContrastRatio(color1: string, color2: string): number;
422
+ /**
423
+ * Determine if a color is light or dark.
424
+ *
425
+ * @param hex - Hex color string
426
+ * @returns True if color is light
427
+ */
428
+ declare function isLightColor(hex: string): boolean;
429
+ /**
430
+ * Get optimal contrast text color for a background.
431
+ *
432
+ * @param background - Background hex color
433
+ * @param lightText - Light text color (default: white)
434
+ * @param darkText - Dark text color (default: black)
435
+ * @returns Best contrast text color
436
+ */
437
+ declare function getContrastText(background: string, lightText?: string, darkText?: string): string;
438
+ /**
439
+ * Lighten a color using HSL.
440
+ * Preserves hue and saturation while increasing lightness.
441
+ *
442
+ * @param hex - Hex color string
443
+ * @param amount - Amount to lighten (0-100 percentage points)
444
+ * @returns Lightened hex color
445
+ */
446
+ declare function lighten(hex: string, amount: number): string;
447
+ /**
448
+ * Darken a color using HSL.
449
+ * Preserves hue and saturation while decreasing lightness.
450
+ *
451
+ * @param hex - Hex color string
452
+ * @param amount - Amount to darken (0-100 percentage points)
453
+ * @returns Darkened hex color
454
+ */
455
+ declare function darken(hex: string, amount: number): string;
456
+ /**
457
+ * Mix two colors together.
458
+ *
459
+ * @param color1 - First hex color
460
+ * @param color2 - Second hex color
461
+ * @param weight - Weight of first color (0-1, default: 0.5)
462
+ * @returns Mixed hex color
463
+ */
464
+ declare function mix(color1: string, color2: string, weight?: number): string;
465
+ /**
466
+ * Create CSS rgba() using a CSS variable channel.
467
+ * Essential for dynamic alpha with CSS custom properties.
468
+ *
469
+ * Supports:
470
+ * - RGB channel strings: "200 250 214"
471
+ * - CSS variables: "var(--palette-primary-mainChannel)"
472
+ * - currentColor (via color-mix)
473
+ *
474
+ * Does NOT support (will throw):
475
+ * - Hex colors: "#00B8D9"
476
+ * - RGB: "rgb(0, 184, 217)"
477
+ * - RGBA: "rgba(0, 184, 217, 1)"
478
+ *
479
+ * @example
480
+ * ```tsx
481
+ * // With CSS variable channel
482
+ * varAlpha('var(--palette-primary-mainChannel)', 0.5)
483
+ * // Returns: "rgba(var(--palette-primary-mainChannel) / 50%)"
484
+ *
485
+ * // With RGB channel string
486
+ * varAlpha('200 250 214', 0.8)
487
+ * // Returns: "rgba(200 250 214 / 80%)"
488
+ *
489
+ * // With percentage opacity
490
+ * varAlpha('var(--palette-primary-mainChannel)', '50%')
491
+ * // Returns: "rgba(var(--palette-primary-mainChannel) / 50%)"
492
+ *
493
+ * // With CSS variable opacity
494
+ * varAlpha('var(--palette-primary-mainChannel)', 'var(--opacity)')
495
+ * // Returns: "rgba(var(--palette-primary-mainChannel) / calc(var(--opacity) * 100%))"
496
+ *
497
+ * // With currentColor
498
+ * varAlpha('currentColor', 0.5)
499
+ * // Returns: "color-mix(in srgb, currentColor 50%, transparent)"
500
+ * ```
501
+ *
502
+ * @param color - CSS variable reference for the RGB channel, RGB channel string, or 'currentColor'
503
+ * @param opacity - Alpha value (0-1 number, percentage string, or CSS variable)
504
+ * @returns CSS rgba/color-mix string
505
+ * @throws Error if color format is unsupported or opacity is invalid
506
+ */
507
+ declare function varAlpha(color: string, opacity?: string | number): string;
508
+
509
+ /**
510
+ * Base Color Scales
511
+ *
512
+ * Foundation colors used across all presets.
513
+ * 11-shade scales (50-950) for maximum flexibility.
514
+ *
515
+ * @module @omnitron-dev/prism/theme/colors/base
516
+ */
517
+
518
+ /**
519
+ * Grey scale - neutral foundation.
520
+ */
521
+ declare const grey: ColorScale;
522
+ /**
523
+ * Blue - default primary.
524
+ */
525
+ declare const blue: ColorScale;
526
+ /**
527
+ * Green - success/teal variant.
528
+ */
529
+ declare const green: ColorScale;
530
+ /**
531
+ * Purple - secondary.
532
+ */
533
+ declare const purple: ColorScale;
534
+ /**
535
+ * Red - error/destructive.
536
+ */
537
+ declare const red: ColorScale;
538
+ /**
539
+ * Orange - warning.
540
+ */
541
+ declare const orange: ColorScale;
542
+ /**
543
+ * Light Blue - info.
544
+ */
545
+ declare const lightBlue: ColorScale;
546
+ /**
547
+ * Basic black and white.
548
+ */
549
+ declare const basic: {
550
+ readonly white: "#FFFFFF";
551
+ readonly black: "#000000";
552
+ };
553
+ /**
554
+ * All base color scales.
555
+ */
556
+ declare const baseColors: {
557
+ readonly grey: ColorScale;
558
+ readonly blue: ColorScale;
559
+ readonly green: ColorScale;
560
+ readonly purple: ColorScale;
561
+ readonly red: ColorScale;
562
+ readonly orange: ColorScale;
563
+ readonly lightBlue: ColorScale;
564
+ readonly basic: {
565
+ readonly white: "#FFFFFF";
566
+ readonly black: "#000000";
567
+ };
568
+ };
569
+
570
+ /**
571
+ * Luxury Preset Colors
572
+ *
573
+ * Rich, elegant color scales with gold/amber tones.
574
+ *
575
+ * @module @omnitron-dev/prism/theme/colors/luxury
576
+ */
577
+
578
+ /**
579
+ * Luxury Primary - Rich Gold/Amber.
580
+ */
581
+ declare const luxuryPrimary: ColorScale;
582
+ /**
583
+ * Luxury Secondary - Deep Purple.
584
+ */
585
+ declare const luxurySecondary: ColorScale;
586
+ /**
587
+ * Luxury Neutral - Warm Grey.
588
+ */
589
+ declare const luxuryNeutral: ColorScale;
590
+ /**
591
+ * Luxury Error - Muted Red.
592
+ */
593
+ declare const luxuryError: ColorScale;
594
+ /**
595
+ * Luxury Warning - Rich Amber.
596
+ */
597
+ declare const luxuryWarning: ColorScale;
598
+ /**
599
+ * Luxury Success - Forest Green.
600
+ */
601
+ declare const luxurySuccess: ColorScale;
602
+ /**
603
+ * Luxury Info - Steel Blue.
604
+ */
605
+ declare const luxuryInfo: ColorScale;
606
+ /**
607
+ * All luxury colors.
608
+ */
609
+ declare const luxuryColors: {
610
+ readonly primary: ColorScale;
611
+ readonly secondary: ColorScale;
612
+ readonly neutral: ColorScale;
613
+ readonly error: ColorScale;
614
+ readonly warning: ColorScale;
615
+ readonly success: ColorScale;
616
+ readonly info: ColorScale;
617
+ };
618
+
619
+ /**
620
+ * Typography System
621
+ *
622
+ * Typography configuration for Prism themes.
623
+ *
624
+ * @module @omnitron-dev/prism/theme/typography
625
+ */
626
+
627
+ /** MUI Typography options type */
628
+ type TypographyOptions = NonNullable<ThemeOptions['typography']>;
629
+ /**
630
+ * Default typography configuration.
631
+ */
632
+ declare const typography: ThemeTypography;
633
+ /**
634
+ * Create MUI typography options from Prism typography config.
635
+ *
636
+ * @param config - Typography configuration
637
+ * @returns MUI typography options
638
+ */
639
+ declare function createTypography(config: ThemeTypography): TypographyOptions;
640
+
641
+ /**
642
+ * Shadow System
643
+ *
644
+ * Shadow configuration for Prism themes.
645
+ *
646
+ * @module @omnitron-dev/prism/theme/shadows
647
+ */
648
+
649
+ /**
650
+ * Default shadows array (MUI expects 25 shadows).
651
+ */
652
+ declare const shadows: Shadows;
653
+ /**
654
+ * Create shadows with optional opacity multiplier for dark mode.
655
+ *
656
+ * @param primaryColor - Primary color for tinted shadows (reserved for future)
657
+ * @param opacityMultiplier - Multiplier for shadow opacity (default: 1, use 0.4-0.6 for dark mode)
658
+ * @returns Shadows array with adjusted opacity
659
+ */
660
+ declare function createShadows(primaryColor?: string, opacityMultiplier?: number): Shadows;
661
+ /**
662
+ * Dark mode shadow - subtle shadow for dark backgrounds.
663
+ */
664
+ declare const darkShadow = "0px 0px 0px 1px rgba(255, 255, 255, 0.1)";
665
+
666
+ /**
667
+ * Theme Mixins
668
+ *
669
+ * Reusable style utilities for component overrides.
670
+ * Based on Minimals template patterns.
671
+ *
672
+ * @module @omnitron-dev/prism/theme/mixins
673
+ */
674
+
675
+ /**
676
+ * Color key types for style variants.
677
+ */
678
+ type PaletteColorKey = 'primary' | 'secondary' | 'info' | 'success' | 'warning' | 'error';
679
+ type CommonColorsKeys = 'black' | 'white';
680
+ type ColorKey = CommonColorsKeys | PaletteColorKey | 'default' | 'inherit';
681
+ /**
682
+ * Options for style variants.
683
+ */
684
+ interface StyleOptions {
685
+ hover?: boolean | CSSObject;
686
+ }
687
+ /**
688
+ * Options for paper styles.
689
+ */
690
+ interface PaperStyleOptions {
691
+ blur?: number;
692
+ color?: string;
693
+ dropdown?: boolean;
694
+ }
695
+ /**
696
+ * Background gradient options.
697
+ */
698
+ interface BgGradientOptions {
699
+ images?: string[];
700
+ sizes?: string[];
701
+ positions?: string[];
702
+ colors?: string[];
703
+ direction?: string;
704
+ }
705
+
706
+ /**
707
+ * Generate filled style variant for components.
708
+ *
709
+ * @example
710
+ * ```tsx
711
+ * // In component styleOverrides
712
+ * ...filledStyles(theme, 'primary', { hover: true })
713
+ * ...filledStyles(theme, 'inherit', { hover: { boxShadow: theme.vars.customShadows.z8 } })
714
+ * ```
715
+ */
716
+ declare function filledStyles(theme: Theme, colorKey: ColorKey, options?: StyleOptions): CSSObject;
717
+ /**
718
+ * Generate soft style variant for components.
719
+ *
720
+ * @example
721
+ * ```tsx
722
+ * // In component styleOverrides
723
+ * ...softStyles(theme, 'primary')
724
+ * ...softStyles(theme, 'inherit', { hover: true })
725
+ * ```
726
+ */
727
+ declare function softStyles(theme: Theme, colorKey: ColorKey, options?: StyleOptions): CSSObject;
728
+ /**
729
+ * Generate background gradient styles.
730
+ *
731
+ * @example
732
+ * ```tsx
733
+ * ...bgGradient({
734
+ * colors: ['rgba(0,0,0,0.5)', 'rgba(0,0,0,0.8)'],
735
+ * direction: 'to bottom'
736
+ * })
737
+ * ```
738
+ */
739
+ declare function bgGradient(options: BgGradientOptions): CSSObject;
740
+ /**
741
+ * Generate blur background styles.
742
+ *
743
+ * @example
744
+ * ```tsx
745
+ * ...bgBlur({ blur: 20, color: 'rgba(255,255,255,0.8)' })
746
+ * ```
747
+ */
748
+ declare function bgBlur(options: {
749
+ blur?: number;
750
+ color?: string;
751
+ }): CSSObject;
752
+ /**
753
+ * Generate paper styles with glass effect.
754
+ *
755
+ * @example
756
+ * ```tsx
757
+ * ...paperStyles(theme, { dropdown: true })
758
+ * ```
759
+ */
760
+ declare function paperStyles(theme: Theme, options?: PaperStyleOptions): CSSObject;
761
+ /**
762
+ * Generate menu item styles.
763
+ *
764
+ * @example
765
+ * ```tsx
766
+ * ...menuItemStyles(theme)
767
+ * ```
768
+ */
769
+ declare function menuItemStyles(theme: Theme): CSSObject;
770
+ /**
771
+ * Generate max lines text truncation.
772
+ *
773
+ * @example
774
+ * ```tsx
775
+ * ...maxLine({ lines: 2 })
776
+ * ```
777
+ */
778
+ declare function maxLine(options: {
779
+ lines: number;
780
+ lineHeight?: number;
781
+ }): CSSObject;
782
+ /**
783
+ * Generate text gradient effect.
784
+ *
785
+ * @example
786
+ * ```tsx
787
+ * ...textGradient('to right', '#FF5630', '#00AB55')
788
+ * ```
789
+ */
790
+ declare function textGradient(direction: string, ...colors: string[]): CSSObject;
791
+ /**
792
+ * Generate border gradient effect using background-clip trick.
793
+ *
794
+ * @example
795
+ * ```tsx
796
+ * ...borderGradient({ color: 'linear-gradient(135deg, #FF5630, #00AB55)', borderWidth: 2 })
797
+ * ```
798
+ */
799
+ declare function borderGradient(options: {
800
+ color?: string;
801
+ borderWidth?: number;
802
+ borderRadius?: number;
803
+ }): CSSObject;
804
+ /**
805
+ * Generate theme-aware scrollbar styles.
806
+ * Uses CSS variables for proper dark mode support.
807
+ *
808
+ * @example
809
+ * ```tsx
810
+ * ...scrollbarStyles(theme)
811
+ * ```
812
+ */
813
+ declare function scrollbarStyles(theme: Theme): CSSObject;
814
+ /**
815
+ * MUI mixins configuration.
816
+ */
817
+ declare const mixins: {
818
+ toolbar: {
819
+ minHeight: number;
820
+ '@media (min-width:0px)': {
821
+ '@media (orientation: landscape)': {
822
+ minHeight: number;
823
+ };
824
+ };
825
+ '@media (min-width:600px)': {
826
+ minHeight: number;
827
+ };
828
+ };
829
+ hideScrollX: {
830
+ msOverflowStyle: "none";
831
+ scrollbarWidth: "none";
832
+ overflowX: "auto";
833
+ '&::-webkit-scrollbar': {
834
+ display: string;
835
+ };
836
+ };
837
+ hideScrollY: {
838
+ msOverflowStyle: "none";
839
+ scrollbarWidth: "none";
840
+ overflowY: "auto";
841
+ '&::-webkit-scrollbar': {
842
+ display: string;
843
+ };
844
+ };
845
+ bgBlur: typeof bgBlur;
846
+ bgGradient: typeof bgGradient;
847
+ maxLine: typeof maxLine;
848
+ softStyles: typeof softStyles;
849
+ filledStyles: typeof filledStyles;
850
+ paperStyles: typeof paperStyles;
851
+ menuItemStyles: typeof menuItemStyles;
852
+ varAlpha: typeof varAlpha;
853
+ textGradient: typeof textGradient;
854
+ borderGradient: typeof borderGradient;
855
+ scrollbarStyles: typeof scrollbarStyles;
856
+ };
857
+ /**
858
+ * Hide scrollbar mixin.
859
+ */
860
+ declare const hideScrollbarMixin: {
861
+ scrollbarWidth: "none";
862
+ msOverflowStyle: "none";
863
+ '&::-webkit-scrollbar': {
864
+ display: string;
865
+ };
866
+ };
867
+ /**
868
+ * Custom scrollbar mixin.
869
+ */
870
+ declare function customScrollbarMixin(theme: Theme): CSSObject;
871
+ /**
872
+ * Text overflow ellipsis mixin.
873
+ */
874
+ declare const textEllipsisMixin: {
875
+ overflow: string;
876
+ textOverflow: string;
877
+ whiteSpace: "nowrap";
878
+ };
879
+ /**
880
+ * Multi-line text overflow mixin.
881
+ */
882
+ declare function multiLineEllipsisMixin(lines: number): {
883
+ overflow: string;
884
+ display: string;
885
+ WebkitBoxOrient: "vertical";
886
+ WebkitLineClamp: number;
887
+ };
888
+ /**
889
+ * Focus visible ring mixin.
890
+ */
891
+ declare const focusRingMixin: {
892
+ '&:focus-visible': {
893
+ outline: string;
894
+ boxShadow: string;
895
+ };
896
+ };
897
+ /**
898
+ * Glass/blur background mixin.
899
+ */
900
+ declare const glassMixin: {
901
+ backdropFilter: string;
902
+ backgroundColor: string;
903
+ };
904
+
905
+ /**
906
+ * Component Overrides
907
+ *
908
+ * MUI component customizations for Prism themes.
909
+ * Combines best practices from Minimals and Aurora templates.
910
+ *
911
+ * Key Features:
912
+ * - Density-based spacing (compact/standard/comfortable)
913
+ * - Custom variants (soft, dashed, shapes)
914
+ * - Refined input styling with proper typography
915
+ * - Custom checkbox/radio/switch icons
916
+ * - Full CSS variable integration
917
+ *
918
+ * @module @omnitron-dev/prism/theme/components
919
+ */
920
+
921
+ /**
922
+ * Generate MUI component overrides based on configuration.
923
+ * Combines best practices from Minimals (refined inputs, custom shadows)
924
+ * and Aurora (compact dimensions, shape variants).
925
+ *
926
+ * @param config - Components configuration
927
+ * @returns MUI components overrides
928
+ */
929
+ declare function componentOverrides(config: ComponentsConfig): Components<Theme> & Record<string, unknown>;
930
+
931
+ /**
932
+ * Button Component Overrides
933
+ *
934
+ * MUI Button customization with custom variants: soft, dashed, shapes.
935
+ *
936
+ * @module @omnitron-dev/prism/theme/components/Button
937
+ */
938
+
939
+ declare module '@mui/material/Button' {
940
+ interface ButtonPropsVariantOverrides {
941
+ /** Soft variant - subtle background with colored text */
942
+ soft: true;
943
+ /** Dashed variant - dashed border */
944
+ dashed: true;
945
+ }
946
+ interface ButtonPropsColorOverrides {
947
+ /** Neutral color option */
948
+ neutral: true;
949
+ }
950
+ interface ButtonPropsSizeOverrides {
951
+ /** Extra-large size */
952
+ xLarge: true;
953
+ }
954
+ interface ButtonOwnProps {
955
+ /** Shape variant for icon buttons */
956
+ shape?: 'square' | 'circle';
957
+ }
958
+ }
959
+ declare function createButtonOverrides(config: ComponentsConfig): Components$1<Theme$1>['MuiButton'];
960
+ declare function createButtonBaseOverrides(): Components$1<Theme$1>['MuiButtonBase'];
961
+ declare function createButtonGroupOverrides(config: ComponentsConfig): Components$1<Theme$1>['MuiButtonGroup'];
962
+
963
+ /**
964
+ * Default Theme Preset
965
+ *
966
+ * A neutral, modern theme suitable for most applications.
967
+ *
968
+ * @module @omnitron-dev/prism/theme/presets/default
969
+ */
970
+
971
+ /**
972
+ * Default theme preset.
973
+ */
974
+ declare const defaultPreset: ThemePresetDefinition;
975
+
976
+ /**
977
+ * Luxury Theme Preset
978
+ *
979
+ * A rich, elegant theme with deep colors and premium feel.
980
+ *
981
+ * @module @omnitron-dev/prism/theme/presets/luxury
982
+ */
983
+
984
+ /**
985
+ * Luxury theme preset.
986
+ */
987
+ declare const luxuryPreset: ThemePresetDefinition;
988
+
989
+ /**
990
+ * Arctic Theme Preset
991
+ *
992
+ * A cool, crisp blue theme inspired by northern landscapes.
993
+ *
994
+ * @module @omnitron-dev/prism/theme/presets/arctic
995
+ */
996
+
997
+ /**
998
+ * Arctic theme preset.
999
+ */
1000
+ declare const arcticPreset: ThemePresetDefinition;
1001
+
1002
+ /**
1003
+ * Theme Presets Index
1004
+ *
1005
+ * @module @omnitron-dev/prism/theme/presets
1006
+ */
1007
+
1008
+ /**
1009
+ * All available preset names.
1010
+ */
1011
+ declare const presetNames: ThemePreset[];
1012
+ /**
1013
+ * Get a theme preset by name.
1014
+ *
1015
+ * @param name - Preset name
1016
+ * @returns Theme preset definition
1017
+ * @throws If preset is not found
1018
+ */
1019
+ declare function getPreset(name: ThemePreset): ThemePresetDefinition;
1020
+
1021
+ /**
1022
+ * CSS Variables System
1023
+ *
1024
+ * Utilities for generating and managing CSS variables.
1025
+ *
1026
+ * @module @omnitron-dev/prism/theme/css-variables
1027
+ */
1028
+
1029
+ /**
1030
+ * CSS variable definitions.
1031
+ * Uses an index signature since keys are dynamically generated based on prefix.
1032
+ */
1033
+ interface CssVariables {
1034
+ [key: string]: string;
1035
+ }
1036
+ /**
1037
+ * Default CSS variable values.
1038
+ */
1039
+ declare const cssVariables: CssVariables;
1040
+ /**
1041
+ * Generate CSS variables from a Prism theme.
1042
+ *
1043
+ * @param theme - Prism theme
1044
+ * @param config - CSS variables configuration
1045
+ * @returns CSS variables object
1046
+ */
1047
+ declare function generateCssVariables(theme: PrismTheme, config: CssVariablesConfig): CssVariables;
1048
+
1049
+ export { type ActionColors, type BackgroundColors, type BuildPaletteOptions, COLOR_GROUPS, ChartPalette, ColorGroup, ColorScale, ColorScaleWithChannels, ComponentDensity, ComponentsConfig, type CreatePrismThemeOptions, CssVariablesConfig, PRESET_DISPLAY_NAMES, PRESET_INHERENT_MODE, PRESET_NAMES, PaletteColor, PaletteColorWithChannels, PrismTheme, type SupportedLocale, type TextColors, ThemeDirection, ThemeMode, ThemePreset, VibrantPalette, applyPrimaryOverride, arcticPreset, baseColors, basic, blue, buildAction, buildBackground, buildChartColors, buildPalette, buildPaletteColor, buildText, buildVibrant, componentOverrides, createButtonBaseOverrides, createButtonGroupOverrides, createButtonOverrides, createPaletteColorFromScale, createPrismTheme, createShadows, createTypography, cssVarRgba, cssVariables, customScrollbarMixin, darkShadow, darken, defaultDarkPalette, defaultLightPalette, defaultPreset, focusRingMixin, generateColorScale, generateColorScaleWithChannels, generateCssVariables, generatePaletteChannel, generatePaletteColorWithChannels, getContrastRatio, getContrastText, getLuminance, getPreset, getPresetDisplayName, glassMixin, green, grey, hexToHsl, hexToRgb, hexToRgbChannel, hideScrollbarMixin, hslToHex, invertColorScale, isLightColor, lightBlue, lighten, luxuryColors, luxuryError, luxuryInfo, luxuryNeutral, luxuryPreset, luxuryPrimary, luxurySecondary, luxurySuccess, luxuryWarning, mix, mixins, multiLineEllipsisMixin, orange, presetNames, purple, red, rgbToHex, rgba, shadows, textEllipsisMixin, typography };