@m4l/styles 3.2.3 → 6.1.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.
- package/config.d.ts +1 -1
- package/index.js +20 -20
- package/package.json +1 -1
- package/theme/index-BZonCMpk.js +196 -0
- package/theme/index.d.ts +2 -1
- package/theme/ourTheme.d.ts +2 -0
- package/theme/overrides/M4LExtendedComponents/{index-C4PXddLa.js → index-BO_x8lkT.js} +256 -255
- package/theme/overrides/M4LRHFComponents/{index-BRZVeOM5.js → index-Dv4h8DSV.js} +34 -34
- package/theme/overrides/MUIComponents/Avatar.d.ts +1 -1
- package/theme/overrides/MUIComponents/Input.d.ts +1 -1
- package/theme/overrides/MUIComponents/Progress.d.ts +1 -1
- package/theme/overrides/MUIComponents/ToggleButton.d.ts +2 -2
- package/theme/overrides/MUIComponents/{index-XoLdmZP6.js → index-DrBJTI1s.js} +61 -62
- package/theme/overrides/{index-B9xZa27y.js → index-DLjfQaz-.js} +9 -9
- package/theme/palette/baseOpacityColors.d.ts +3 -0
- package/theme/palette/defaultColors.d.ts +14 -0
- package/theme/palette/index.d.ts +0 -1
- package/theme/palette/presetColors.d.ts +18 -4
- package/theme/palette/semanticColors.d.ts +16 -0
- package/theme/palette-voCQl3kP.js +792 -0
- package/theme/{shadows-GTYqExFA.js → shadows-Cek_1mpN.js} +1 -1
- package/theme/sizes/baseBorderRadius.d.ts +6 -0
- package/theme/sizes/baseSizes.d.ts +5 -0
- package/theme/sizes/index.d.ts +1 -0
- package/theme/sizes/pointerQr.d.ts +21 -0
- package/theme/sizes/size.d.ts +2 -0
- package/theme/sizes/types.d.ts +73 -0
- package/types/augmentations.d.ts +159 -155
- package/types/types.d.ts +70 -33
- package/utils/{getColorPresets-CXZaM9oS.js → getColorPresets-DgmrCj5l.js} +1 -1
- package/utils/getColorPresets.d.ts +4 -4
- package/utils/getColorState.d.ts +2 -2
- package/utils/getPaletteByPreset.d.ts +127 -0
- package/utils/index.d.ts +1 -0
- package/vite-env.d.ts +3 -3
- package/theme/defaultThemeOptions-BlJvKCE6.js +0 -24
- package/theme/defaultThemeOptions.d.ts +0 -1
- package/theme/index-l0sNRNKZ.js +0 -1
- package/theme/palette/palette.d.ts +0 -6
- package/theme/palette/stateColors.d.ts +0 -2
- package/theme/palette-DM0gXxA2.js +0 -584
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { alpha as a } from "@mui/material/styles";
|
|
2
|
-
import { G as n, B as s, C as e } from "./palette-
|
|
2
|
+
import { G as n, B as s, C as e } from "./palette-voCQl3kP.js";
|
|
3
3
|
const o = n[500], c = "#000000", t = (r) => {
|
|
4
4
|
const p = a(r, 0.2), x = a(r, 0.14), $ = a(r, 0.12);
|
|
5
5
|
return [
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './types';
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { PointerQrSizes } from "./types";
|
|
2
|
+
/**
|
|
3
|
+
* Conjunto de valores que utilizan los desarrolladores para definir categorías de tamaños y espacios en la aplicación web, aplicados principalmente en modalidad de cursor 'pointer'.
|
|
4
|
+
*
|
|
5
|
+
* - base: Clasificación de altura para componentes generales, que no pertenecen a las categorías de acción ni contenedores. Estos componentes suelen ser de uso común sin funcionalidad específica de interacción.
|
|
6
|
+
*
|
|
7
|
+
* - action: Clasificación de altura para componentes de tipo acción, como MenuItems, HeaderPopover, IconButton, Button, entre otros. Estos componentes se utilizan para interacciones directas del usuario.
|
|
8
|
+
*
|
|
9
|
+
* - container: Clasificación de altura para componentes que funcionan como contenedores, como DynamicFilter, DynamicSort, HeaderModule, Tabs, etc. Estos agrupan o contienen otros elementos o funcionalidades.
|
|
10
|
+
*/
|
|
11
|
+
export declare const POINTER_QR_DESKTOP_SIZES: PointerQrSizes;
|
|
12
|
+
/**
|
|
13
|
+
* Conjunto de valores que utilizan los desarrolladores para definir categorías de tamaños y espacios en la aplicación web, aplicados principalmente en modalidad de cursor 'touch'.
|
|
14
|
+
*
|
|
15
|
+
* - base: Clasificación de altura para componentes generales, que no pertenecen a las categorías de acción ni contenedores. Estos componentes suelen ser de uso común sin funcionalidad específica de interacción.
|
|
16
|
+
*
|
|
17
|
+
* - action: Clasificación de altura para componentes de tipo acción, como MenuItems, HeaderPopover, IconButton, Button, entre otros. Estos componentes se utilizan para interacciones directas del usuario.
|
|
18
|
+
*
|
|
19
|
+
* - container: Clasificación de altura para componentes que funcionan como contenedores, como DynamicFilter, DynamicSort, HeaderModule, Tabs, etc. Estos agrupan o contienen otros elementos o funcionalidades.
|
|
20
|
+
*/
|
|
21
|
+
export declare const POINTER_QR_MOBILE_SIZES: PointerQrSizes;
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Conjunto de valores predeterminados utilizados para definir el radio de borde en los
|
|
3
|
+
* componentes de la aplicación web.
|
|
4
|
+
*/
|
|
5
|
+
export interface BaseBorderRadius {
|
|
6
|
+
'r0': number;
|
|
7
|
+
'r0.5': number;
|
|
8
|
+
'r1': number;
|
|
9
|
+
'r1.5': number;
|
|
10
|
+
'r2': number;
|
|
11
|
+
'r3': number;
|
|
12
|
+
'r4': number;
|
|
13
|
+
}
|
|
14
|
+
/**
|
|
15
|
+
* Conjunto de valores predeterminados utilizados para definir el tamaño y espaciados en los componentes de la aplicación web.
|
|
16
|
+
*/
|
|
17
|
+
export interface BaseSpacings {
|
|
18
|
+
'sp0': number;
|
|
19
|
+
'sp0.5': number;
|
|
20
|
+
'sp1': number;
|
|
21
|
+
'sp2': number;
|
|
22
|
+
'sp3': number;
|
|
23
|
+
'sp3.5': number;
|
|
24
|
+
'sp4': number;
|
|
25
|
+
'sp5': number;
|
|
26
|
+
'sp6': number;
|
|
27
|
+
'sp7': number;
|
|
28
|
+
'sp8': number;
|
|
29
|
+
'sp9': number;
|
|
30
|
+
'sp10': number;
|
|
31
|
+
'sp10.5': number;
|
|
32
|
+
'sp11': number;
|
|
33
|
+
'sp12': number;
|
|
34
|
+
'sp13': number;
|
|
35
|
+
'sp14': number;
|
|
36
|
+
'sp14.5': number;
|
|
37
|
+
}
|
|
38
|
+
/**
|
|
39
|
+
* type usado para tipar las props sizes de los componentes o sus derivaciones
|
|
40
|
+
*/
|
|
41
|
+
export declare type Sizes = 'small' | 'medium' | 'large';
|
|
42
|
+
/**
|
|
43
|
+
* Representa al conjunto de valores de tamaño que tienen en cuenta la variación de tamaño en la aplicación web.
|
|
44
|
+
* Puede ser small, medium y large.
|
|
45
|
+
*/
|
|
46
|
+
export declare type SizesValues = Record<Sizes, number>;
|
|
47
|
+
/**
|
|
48
|
+
* Representa a los conjuntos de valores que utilizan los desarroladores para definir diferentes categorías de componentes en tamaños y espacios.
|
|
49
|
+
* base: Es la clasificación de altura para componentes de tipo general, los cuales no son de categoría de acción ni de categoría contenedora.
|
|
50
|
+
* action: Es la clasificación de altura para componentes de tipo acción, los cuales son MenuItems, HeaderPopover, IconButton, Button, etc.
|
|
51
|
+
* container: Es la clasificación de altura para componentes de tipo contenedor, los cuales son DinamicFilter, DinamicSort, HeaderModule, Tabs, etc.
|
|
52
|
+
*/
|
|
53
|
+
export declare type SizesComponentsTypes = 'base' | 'action' | 'container';
|
|
54
|
+
/**
|
|
55
|
+
* Representa el conjunto de tamaños separados en categorías de componentes para la aplicación web.
|
|
56
|
+
* Se dividen en los siguientes tipos; base, action y container. Cada opción de categoría define
|
|
57
|
+
* los tamaños que pueden ser small, medium y large.
|
|
58
|
+
*/
|
|
59
|
+
export declare type PointerQrSizes = Record<SizesComponentsTypes, SizesValues>;
|
|
60
|
+
/**
|
|
61
|
+
* Representa las opciones de tamaño para los dispositivos desktop y mobile en la aplicación web,
|
|
62
|
+
* cada opción contiene el grupo PointerQrSizes adecuados al tipo de dispositivo según figma.
|
|
63
|
+
**/
|
|
64
|
+
/**
|
|
65
|
+
* Representa la coleccción completa de tamaños y espacios en la aplicación, contiene valores para
|
|
66
|
+
* uso de dispositivo móvil, escritorio, borders y valores base para ser usados por el desarrolador
|
|
67
|
+
* en los componentes de la aplicación web.
|
|
68
|
+
*/
|
|
69
|
+
export interface Size {
|
|
70
|
+
mobile: PointerQrSizes;
|
|
71
|
+
desktop: PointerQrSizes;
|
|
72
|
+
borderRadius: BaseBorderRadius;
|
|
73
|
+
}
|
package/types/augmentations.d.ts
CHANGED
|
@@ -1,155 +1,159 @@
|
|
|
1
|
-
import { Breakpoints } from '@mui/material';
|
|
2
|
-
|
|
3
|
-
import type { CustomShadowOptions } from '../theme';
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
default: string;
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
disabled: string;
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
general: {
|
|
77
|
-
scrollBar: string;
|
|
78
|
-
gridHover: string;
|
|
79
|
-
};
|
|
80
|
-
}
|
|
81
|
-
|
|
82
|
-
interface ColorSchemeOverrides {
|
|
83
|
-
finalTheme?: true;
|
|
84
|
-
}
|
|
85
|
-
|
|
86
|
-
interface CssVarsTheme {
|
|
87
|
-
generalSettings: {
|
|
88
|
-
isMobile: boolean;
|
|
89
|
-
}
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
1
|
+
import { Breakpoints } from '@mui/material';
|
|
2
|
+
|
|
3
|
+
import type { CustomShadowOptions } from '../theme';
|
|
4
|
+
import type { BaseBorderRadius, Size } from '../theme/sizes/types';
|
|
5
|
+
|
|
6
|
+
declare module '@mui/material' {
|
|
7
|
+
interface Color {
|
|
8
|
+
0: string;
|
|
9
|
+
500_8: string;
|
|
10
|
+
500_12: string;
|
|
11
|
+
500_16: string;
|
|
12
|
+
500_24: string;
|
|
13
|
+
500_32: string;
|
|
14
|
+
500_48: string;
|
|
15
|
+
500_56: string;
|
|
16
|
+
500_80: string;
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
declare module '@mui/material/styles' {
|
|
21
|
+
interface PaletteColor {
|
|
22
|
+
//TODO: Documentar los colores segun figma
|
|
23
|
+
// light: string; *** Por compatibilidad con MUI
|
|
24
|
+
// main: string; ***
|
|
25
|
+
// dark: string; *** Por compatibilidad con MUI
|
|
26
|
+
// contrastText: string; ***
|
|
27
|
+
|
|
28
|
+
focusActive: string;
|
|
29
|
+
focusVisible: string;
|
|
30
|
+
hover: string;
|
|
31
|
+
hoverOpacity: string;
|
|
32
|
+
opacity: string;
|
|
33
|
+
toneOpacity: string;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
export interface TypeBackground {
|
|
37
|
+
neutral: string;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
interface Palette {
|
|
41
|
+
mode: 'light' | 'dark';
|
|
42
|
+
secondary: never;
|
|
43
|
+
skeleton: { default: string; transition: string };
|
|
44
|
+
default: PaletteColor;
|
|
45
|
+
border: {
|
|
46
|
+
main: string;
|
|
47
|
+
default: string;
|
|
48
|
+
secondary: string;
|
|
49
|
+
dens: string;
|
|
50
|
+
disabled: string;
|
|
51
|
+
error: string;
|
|
52
|
+
};
|
|
53
|
+
general: {
|
|
54
|
+
scrollBar: string;
|
|
55
|
+
gridHover: string;
|
|
56
|
+
};
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
/**
|
|
60
|
+
* Interfaz de colores de material-ui, define las opciones de personalización de la paleta de colores que se
|
|
61
|
+
* pueden usar al crear un tema con la función `createTheme`.
|
|
62
|
+
*/
|
|
63
|
+
interface PaletteOptions {
|
|
64
|
+
mode: 'light' | 'dark';
|
|
65
|
+
secondary: never;
|
|
66
|
+
skeleton: { default: string; transition: string };
|
|
67
|
+
border: {
|
|
68
|
+
main: string;
|
|
69
|
+
default: string;
|
|
70
|
+
secondary: string;
|
|
71
|
+
dens: string;
|
|
72
|
+
disabled: string;
|
|
73
|
+
error: string;
|
|
74
|
+
};
|
|
75
|
+
default: PaletteColor;
|
|
76
|
+
general: {
|
|
77
|
+
scrollBar: string;
|
|
78
|
+
gridHover: string;
|
|
79
|
+
};
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
interface ColorSchemeOverrides {
|
|
83
|
+
finalTheme?: true;
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
interface CssVarsTheme {
|
|
87
|
+
generalSettings: {
|
|
88
|
+
isMobile: boolean;
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
interface Theme extends CssVarsTheme {
|
|
94
|
+
stretch: boolean;
|
|
95
|
+
customShadows: CustomShadowOptions;
|
|
96
|
+
breakpoints: Breakpoints;
|
|
97
|
+
/**
|
|
98
|
+
* Colección de tamaños y espaciados base en el sistema de diseño
|
|
99
|
+
*/
|
|
100
|
+
size: Size;
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
interface CssVarsThemeOptions {
|
|
104
|
+
generalSettings: {
|
|
105
|
+
isMobile: boolean;
|
|
106
|
+
};
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
interface ThemeVars {
|
|
110
|
+
customShadows: CustomShadowOptions;
|
|
111
|
+
/**
|
|
112
|
+
* Colección de tamaños y espaciados base en el sistema de diseño
|
|
113
|
+
*/
|
|
114
|
+
size: Size;
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
interface ColorSystem {
|
|
118
|
+
typography: TypographyVariants;
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
interface TypeBackground {
|
|
122
|
+
default: string,
|
|
123
|
+
neutral: string,
|
|
124
|
+
surface: string,
|
|
125
|
+
hover: string,
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
interface TypographyVariants {
|
|
129
|
+
subtitle: Record<string, any>;
|
|
130
|
+
subtitleDens: Record<string, any>;
|
|
131
|
+
paragraph: Record<string, any>;
|
|
132
|
+
paragraphDens: Record<string, any>;
|
|
133
|
+
body: Record<string, any>;
|
|
134
|
+
bodyDens: Record<string, any>;
|
|
135
|
+
action: Record<string, any>;
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
interface TypographyVariantsOptions {
|
|
139
|
+
subtitle: React.CSSProperties;
|
|
140
|
+
subtitleDens: React.CSSProperties;
|
|
141
|
+
paragraph: React.CSSProperties;
|
|
142
|
+
paragraphDens: React.CSSProperties;
|
|
143
|
+
body: React.CSSProperties;
|
|
144
|
+
bodyDens: React.CSSProperties;
|
|
145
|
+
action: React.CSSProperties;
|
|
146
|
+
}
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
declare module '@mui/material/Typography' {
|
|
150
|
+
interface TypographyPropsVariantOverrides {
|
|
151
|
+
subtitle: true;
|
|
152
|
+
subtitleDens: true;
|
|
153
|
+
paragraph: true;
|
|
154
|
+
paragraphDens: true;
|
|
155
|
+
body: true;
|
|
156
|
+
bodyDens: true;
|
|
157
|
+
action: true;
|
|
158
|
+
}
|
|
159
|
+
}
|
package/types/types.d.ts
CHANGED
|
@@ -1,16 +1,25 @@
|
|
|
1
|
-
import { PaletteColor } from '@mui/material/styles';
|
|
1
|
+
import { PaletteColor, Theme } from '@mui/material/styles';
|
|
2
2
|
/**
|
|
3
|
-
*
|
|
3
|
+
* Opciones de color seleccionables por un usuario con los que se puede pintar la aplicación.
|
|
4
4
|
*/
|
|
5
|
-
export declare type
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
export declare type
|
|
5
|
+
export declare type ThemeColorOptionsType = 'patronus' | 'turqui' | 'grass' | 'brown' | 'blaze';
|
|
6
|
+
/**
|
|
7
|
+
* Lista de colores semánticos disponibles en la aplicación.
|
|
8
|
+
*/
|
|
9
|
+
export declare type SemanticColorOptionsType = 'info' | 'success' | 'warning' | 'error';
|
|
10
|
+
/**
|
|
11
|
+
* Son los conjuntos de colores que se pueden usar en los componentes y corresponde al tipo PaletteColor
|
|
12
|
+
*/
|
|
13
|
+
export declare type ComponentPalletColor = 'primary' | 'default' | SemanticColorOptionsType;
|
|
10
14
|
export declare type BasePalettes = 'patronusBlue' | 'crayonBlue' | 'middleYellow' | 'acidGreen' | 'grassGreen' | 'desertBeige' | 'turquiBlue' | 'blazeOrange' | 'flameRed' | 'coolGrey' | 'brown' | 'marbleLight' | 'onyx' | 'mint' | 'oxford';
|
|
11
|
-
export declare type BaseOpacityPalettes = 'patronus' | 'turqui' | 'grass' | 'brown' | 'beige' | '
|
|
15
|
+
export declare type BaseOpacityPalettes = 'patronus' | 'turqui' | 'grass' | 'brown' | 'beige' | 'blaze' | 'cool' | 'marble' | 'mint' | 'oxford' | 'middle' | 'acid' | 'flame' | 'crayon';
|
|
12
16
|
export interface Colors {
|
|
13
|
-
|
|
17
|
+
/**
|
|
18
|
+
* ToneOpacity se usa para colorear el fondo de los celdas en el compksonente grid.
|
|
19
|
+
* Requiere un todo de 100 en alpha pero basado en el color de opacidad con fondo ligth o dark.
|
|
20
|
+
*/
|
|
21
|
+
'toneOpacity10': string;
|
|
22
|
+
'toneOpacity20': string;
|
|
14
23
|
10: string;
|
|
15
24
|
20: string;
|
|
16
25
|
30: string;
|
|
@@ -23,36 +32,64 @@ export interface Colors {
|
|
|
23
32
|
100: string;
|
|
24
33
|
}
|
|
25
34
|
export interface OpacityColors {
|
|
26
|
-
4: string;
|
|
27
|
-
6: string;
|
|
28
|
-
8: string;
|
|
29
35
|
10: string;
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
32: string;
|
|
37
|
-
48: string;
|
|
38
|
-
60?: string;
|
|
39
|
-
72?: string;
|
|
36
|
+
20: string;
|
|
37
|
+
30: string;
|
|
38
|
+
40: string;
|
|
39
|
+
50: string;
|
|
40
|
+
60: string;
|
|
41
|
+
70: string;
|
|
40
42
|
}
|
|
41
|
-
export interface
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
43
|
+
export interface PresetColor {
|
|
44
|
+
main: string;
|
|
45
|
+
contrastText: string;
|
|
46
|
+
light: string;
|
|
47
|
+
lighter: string;
|
|
48
|
+
toneOpacityLight: string;
|
|
49
|
+
/**
|
|
50
|
+
* Permite definir fondos de componentes en estados hover y focus dependiendo de la necesidad.
|
|
51
|
+
*/
|
|
52
|
+
opacityLight: string;
|
|
53
|
+
opacityDark: string;
|
|
54
|
+
dark: string;
|
|
55
|
+
darker: string;
|
|
56
|
+
toneOpacityDark: string;
|
|
57
|
+
/**
|
|
58
|
+
* Permite mantener consitencia en el color de tema para los borders en caso de estar en un estado de usuario focus.
|
|
59
|
+
*/
|
|
60
|
+
borderMainDark: string;
|
|
61
|
+
borderMainLight: string;
|
|
48
62
|
}
|
|
63
|
+
/**
|
|
64
|
+
* Lista de colores base en formato Colors
|
|
65
|
+
*/
|
|
49
66
|
export declare type BaseConstantColors = Record<BasePalettes, Colors>;
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
export declare type
|
|
67
|
+
/**
|
|
68
|
+
* Son los colores de las las ocpiones del tema, en formato PresetColor (Mas amplio que el PaletteColor)
|
|
69
|
+
*/
|
|
70
|
+
export declare type ThemePresetColors = Record<ThemeColorOptionsType, PresetColor>;
|
|
71
|
+
/**
|
|
72
|
+
* Son los colores semanticos en formato PresetColor
|
|
73
|
+
*/
|
|
74
|
+
export declare type SemanticPresetColors = Record<SemanticColorOptionsType, PresetColor>;
|
|
75
|
+
/**
|
|
76
|
+
* Son los colores de las ocpiones del tema, en formato PalletColor
|
|
77
|
+
*/
|
|
78
|
+
export declare type ThemePaletteColors = Record<ThemeColorOptionsType, PaletteColor>;
|
|
79
|
+
/**
|
|
80
|
+
* Son las opcines de paleta de colores semánticos en formato PaletteColor
|
|
81
|
+
*/
|
|
82
|
+
export declare type SemanticsPaletteColors = Record<SemanticColorOptionsType, PaletteColor>;
|
|
83
|
+
/**
|
|
84
|
+
* Es la configuración de color que se usa fabricar la paleta "default", se encuentra en formato PaletteColor.
|
|
85
|
+
*/
|
|
86
|
+
export declare type DefaultPresetColor = Omit<PresetColor, 'borderMainDark' | 'borderMainLight' | 'main' | 'contrastText'> & {
|
|
87
|
+
mainLight: string;
|
|
88
|
+
mainDark: string;
|
|
89
|
+
};
|
|
54
90
|
export declare type PresetsOptions = Array<{
|
|
55
91
|
name: string | undefined;
|
|
56
92
|
value: string;
|
|
57
93
|
}>;
|
|
58
94
|
export declare type ColorState = 'warning' | 'delete' | 'info' | 'success';
|
|
95
|
+
export declare type OurTheme = Pick<Theme, 'palette' | 'typography' | 'customShadows' | 'stretch' | 'size'>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export declare const DEFAULT_PRESET:
|
|
3
|
-
export declare const defaultPresetColors:
|
|
4
|
-
export declare function getColorPresets(presetsKey:
|
|
1
|
+
import { PresetColor, ThemeColorOptionsType } from '../types';
|
|
2
|
+
export declare const DEFAULT_PRESET: ThemeColorOptionsType;
|
|
3
|
+
export declare const defaultPresetColors: PresetColor;
|
|
4
|
+
export declare function getColorPresets(presetsKey: ThemeColorOptionsType): PresetColor;
|
|
5
5
|
export default getColorPresets;
|
package/utils/getColorState.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { ComponentPalletColor } from '../types/types';
|
|
2
2
|
import { Theme } from '@mui/material';
|
|
3
|
-
export declare const getColorState: (color:
|
|
3
|
+
export declare const getColorState: (color: ComponentPalletColor, palette: Theme['palette'] | Theme['vars']['palette']) => string;
|