@m4l/styles 0.0.0 → 0.0.2

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@m4l/styles",
3
- "version": "0.0.0",
3
+ "version": "0.0.2",
4
4
  "license": "UNLICENSED",
5
5
  "dependencies": {
6
6
  "@m4l/graphics": "*",
package/theme/index.d.ts CHANGED
@@ -1,7 +1,4 @@
1
1
  export type { CustomShadowOptions } from './shadows';
2
- export type { GradientsPaletteOptions } from './palette';
3
- export type { ChartPaletteOptions } from './palette';
4
- export type { GridPaletteOptions } from './palette';
5
2
  export { defaultThemeOptions } from './defaultThemeOptions';
6
3
  export { shadows, customShadows } from './shadows';
7
4
  export { palette, type ColorSchema } from './palette';
@@ -1,5 +1,5 @@
1
1
  import { Theme } from '@mui/material/styles';
2
- export declare const M4LButton: (theme: Theme) => {
2
+ export declare const M4LButton: (_theme: Theme) => {
3
3
  M4LButton: {
4
4
  styleOverrides: {
5
5
  "&.M4LButton-root": {
@@ -1,5 +1,5 @@
1
1
  import { Theme } from '@mui/material/styles';
2
- export declare const M4LErrorLabel: (theme: Theme) => {
2
+ export declare const M4LErrorLabel: (_theme: Theme) => {
3
3
  M4LErrorLabel: {
4
4
  styleOverrides: {
5
5
  "&.M4LErrorLabel-root": {
@@ -4,6 +4,7 @@ export declare const M4LIcon: (theme: Theme) => {
4
4
  styleOverrides: {
5
5
  "&.M4LIcon-root": {
6
6
  test: string;
7
+ backgroundColor: string;
7
8
  };
8
9
  };
9
10
  };
@@ -1,5 +1,5 @@
1
1
  import { Theme } from '@mui/material/styles';
2
- export declare const M4LIconButton: (theme: Theme) => {
2
+ export declare const M4LIconButton: (_theme: Theme) => {
3
3
  M4LIconButton: {
4
4
  styleOverrides: {
5
5
  "&.M4LIconButton-root": {
@@ -1,5 +1,5 @@
1
1
  import { Theme } from '@mui/material/styles';
2
- export declare const M4LImage: (theme: Theme) => {
2
+ export declare const M4LImage: (_theme: Theme) => {
3
3
  M4LImage: {
4
4
  styleOverrides: {
5
5
  "&.M4LImage-root": {
@@ -1,5 +1,5 @@
1
1
  import { Theme } from '@mui/material/styles';
2
- export declare const M4LImageButton: (theme: Theme) => {
2
+ export declare const M4LImageButton: (_theme: Theme) => {
3
3
  M4LImageButton: {
4
4
  styleOverrides: {
5
5
  "&.M4LImageButton-root": {
@@ -1,5 +1,5 @@
1
1
  import { Theme } from '@mui/material/styles';
2
- export declare const M4LPopover: (theme: Theme) => {
2
+ export declare const M4LPopover: (_theme: Theme) => {
3
3
  M4LPopover: {
4
4
  styleOverrides: {
5
5
  "&.M4LPopover-root": {
@@ -1,5 +1,5 @@
1
1
  import { Theme } from '@mui/material/styles';
2
- export declare const M4LTypography: (theme: Theme) => {
2
+ export declare const M4LTypography: (_theme: Theme) => {
3
3
  M4LTypography: {
4
4
  styleOverrides: {
5
5
  "&.M4LTypography-root": {
@@ -1,5 +1,5 @@
1
1
  import { Theme } from '@mui/material/styles';
2
- export declare const M4LanguagePopover: (theme: Theme) => {
2
+ export declare const M4LanguagePopover: (_theme: Theme) => {
3
3
  M4LanguagePopover: {
4
4
  styleOverrides: {
5
5
  "&.M4LanguagePopover-root": {
@@ -1,5 +1,5 @@
1
1
  import { Theme } from '@mui/material/styles';
2
- export declare const M4LRHFCheckbox: (theme: Theme) => {
2
+ export declare const M4LRHFCheckbox: (_theme: Theme) => {
3
3
  M4LRHFCheckbox: {
4
4
  styleOverrides: {
5
5
  "&.M4LRHFCheckbox-root": {
@@ -1,5 +1,5 @@
1
1
  import { Theme } from '@mui/material/styles';
2
- export declare const M4LRHFTextField: (theme: Theme) => {
2
+ export declare const M4LRHFTextField: (_theme: Theme) => {
3
3
  M4LRHFTextField: {
4
4
  styleOverrides: {
5
5
  "&.M4LRHFTextField-root": {
@@ -1,5 +1,5 @@
1
1
  import { Theme } from '@mui/material/styles';
2
- export declare const M4LRHFTextFieldPassword: (theme: Theme) => {
2
+ export declare const M4LRHFTextFieldPassword: (_theme: Theme) => {
3
3
  M4LRHFTextFieldPassword: {
4
4
  styleOverrides: {
5
5
  "&.M4LRHFTextFieldPassword-root": {
@@ -1,5 +1,5 @@
1
1
  import { Theme } from '@mui/material/styles';
2
- export declare const CmpDisenoTest: (theme: Theme) => {
2
+ export declare const CmpDisenoTest: (_theme: Theme) => {
3
3
  M4LBruceTest: {
4
4
  styleOverrides: {};
5
5
  };
@@ -1,5 +1,5 @@
1
1
  import { Theme } from '@mui/material/styles';
2
- export declare const M4LDynamicFilter: (theme: Theme) => {
2
+ export declare const M4LDynamicFilter: (_theme: Theme) => {
3
3
  M4LDynamicFilter: {
4
4
  styleOverrides: {};
5
5
  };
@@ -1,69 +1,4 @@
1
1
  export declare type ColorSchema = 'primary' | 'secondary' | 'info' | 'success' | 'warning' | 'error';
2
- export interface GradientsPaletteOptions {
3
- primary: string;
4
- info: string;
5
- success: string;
6
- warning: string;
7
- error: string;
8
- }
9
- export interface ChartPaletteOptions {
10
- violet: string[];
11
- blue: string[];
12
- green: string[];
13
- yellow: string[];
14
- red: string[];
15
- }
16
- export interface GridPaletteOptions {
17
- sectionHeader: string;
18
- rowHover: string;
19
- divider: string;
20
- }
21
- declare module '@mui/material/styles/createPalette' {
22
- interface TypeBackground {
23
- neutral: string;
24
- autofill: string;
25
- header: string;
26
- }
27
- interface SimplePaletteColorOptions {
28
- lighter?: string;
29
- darker?: string;
30
- LightSelected?: string;
31
- LightSelectedHover?: string;
32
- DarkSelected?: string;
33
- DarkSelectedHover?: string;
34
- }
35
- interface PaletteColor {
36
- lighter?: string;
37
- darker?: string;
38
- LightSelected?: string;
39
- LightSelectedHover?: string;
40
- DarkSelected?: string;
41
- DarkSelectedHover?: string;
42
- }
43
- interface Palette {
44
- gradients?: GradientsPaletteOptions;
45
- chart: ChartPaletteOptions;
46
- grid?: GridPaletteOptions;
47
- }
48
- interface PaletteOptions {
49
- gradients?: GradientsPaletteOptions;
50
- chart?: ChartPaletteOptions;
51
- grid?: GridPaletteOptions;
52
- }
53
- }
54
- declare module '@mui/material' {
55
- interface Color {
56
- 0: string;
57
- 500_8: string;
58
- 500_12: string;
59
- 500_16: string;
60
- 500_24: string;
61
- 500_32: string;
62
- 500_48: string;
63
- 500_56: string;
64
- 500_80: string;
65
- }
66
- }
67
2
  export declare const GREY: {
68
3
  0: string;
69
4
  100: string;
package/types/index.d.ts CHANGED
@@ -1 +1 @@
1
- export declare type ThemeColorPresets = 'default' | 'purple' | 'cyan' | 'blue' | 'orange' | 'red';
1
+ export * from './types.d';
@@ -0,0 +1,87 @@
1
+ import {CustomShadowOptions } from '../theme'
2
+
3
+ export {};
4
+
5
+ export declare type ThemeColorPresets = 'default' | 'purple' | 'cyan' | 'blue' | 'orange' | 'red';
6
+
7
+ declare module '@mui/material/styles' {
8
+ interface Theme {
9
+ stretch?: boolean;
10
+ customShadows: CustomShadowOptions;
11
+ }
12
+
13
+ interface ThemeOptions {
14
+ stretch?: boolean;
15
+ customShadows?: CustomShadowOptions;
16
+ }
17
+ }
18
+
19
+ export interface GridPaletteOptions {
20
+ sectionHeader: string;
21
+ rowHover: string;
22
+ divider: string;
23
+ }
24
+
25
+ export interface ChartPaletteOptions {
26
+ violet: string[];
27
+ blue: string[];
28
+ green: string[];
29
+ yellow: string[];
30
+ red: string[];
31
+ }
32
+
33
+ export interface GradientsPaletteOptions {
34
+ primary: string;
35
+ info: string;
36
+ success: string;
37
+ warning: string;
38
+ error: string;
39
+ }
40
+
41
+ declare module '@mui/material/styles/createPalette' {
42
+ interface TypeBackground {
43
+ neutral: string;
44
+ autofill: string;
45
+ header: string;
46
+ }
47
+ interface SimplePaletteColorOptions {
48
+ lighter?: string;
49
+ darker?: string;
50
+ LightSelected?: string;
51
+ LightSelectedHover?: string;
52
+ DarkSelected?: string;
53
+ DarkSelectedHover?: string;
54
+ }
55
+ interface PaletteColor {
56
+ lighter?: string;
57
+ darker?: string;
58
+ LightSelected?: string;
59
+ LightSelectedHover?: string;
60
+ DarkSelected?: string;
61
+ DarkSelectedHover?: string;
62
+ }
63
+ interface Palette {
64
+ gradients?: GradientsPaletteOptions;
65
+ chart: ChartPaletteOptions;
66
+ grid?: GridPaletteOptions;
67
+ }
68
+ interface PaletteOptions {
69
+ gradients?: GradientsPaletteOptions;
70
+ chart?: ChartPaletteOptions;
71
+ grid?: GridPaletteOptions;
72
+ }
73
+ }
74
+
75
+ declare module '@mui/material' {
76
+ interface Color {
77
+ 0: string;
78
+ 500_8: string;
79
+ 500_12: string;
80
+ 500_16: string;
81
+ 500_24: string;
82
+ 500_32: string;
83
+ 500_48: string;
84
+ 500_56: string;
85
+ 500_80: string;
86
+ }
87
+ }
@@ -0,0 +1,170 @@
1
+ import { ThemeColorPresets } from '../types';
2
+ export declare const colorPresets: ({
3
+ LightSelected: string;
4
+ LightSelectedHover: string;
5
+ DarkSelected: string;
6
+ DarkSelectedHover: string;
7
+ contrastText: string;
8
+ lighter: string;
9
+ light: string;
10
+ main: string;
11
+ dark: string;
12
+ darker: string;
13
+ name: string;
14
+ } | {
15
+ name: string;
16
+ lighter: string;
17
+ light: string;
18
+ main: string;
19
+ dark: string;
20
+ darker: string;
21
+ contrastText: string;
22
+ })[];
23
+ export declare const defaultPreset: {
24
+ LightSelected: string;
25
+ LightSelectedHover: string;
26
+ DarkSelected: string;
27
+ DarkSelectedHover: string;
28
+ contrastText: string;
29
+ lighter: string;
30
+ light: string;
31
+ main: string;
32
+ dark: string;
33
+ darker: string;
34
+ name: string;
35
+ } | {
36
+ name: string;
37
+ lighter: string;
38
+ light: string;
39
+ main: string;
40
+ dark: string;
41
+ darker: string;
42
+ contrastText: string;
43
+ };
44
+ export declare const purplePreset: {
45
+ LightSelected: string;
46
+ LightSelectedHover: string;
47
+ DarkSelected: string;
48
+ DarkSelectedHover: string;
49
+ contrastText: string;
50
+ lighter: string;
51
+ light: string;
52
+ main: string;
53
+ dark: string;
54
+ darker: string;
55
+ name: string;
56
+ } | {
57
+ name: string;
58
+ lighter: string;
59
+ light: string;
60
+ main: string;
61
+ dark: string;
62
+ darker: string;
63
+ contrastText: string;
64
+ };
65
+ export declare const cyanPreset: {
66
+ LightSelected: string;
67
+ LightSelectedHover: string;
68
+ DarkSelected: string;
69
+ DarkSelectedHover: string;
70
+ contrastText: string;
71
+ lighter: string;
72
+ light: string;
73
+ main: string;
74
+ dark: string;
75
+ darker: string;
76
+ name: string;
77
+ } | {
78
+ name: string;
79
+ lighter: string;
80
+ light: string;
81
+ main: string;
82
+ dark: string;
83
+ darker: string;
84
+ contrastText: string;
85
+ };
86
+ export declare const bluePreset: {
87
+ LightSelected: string;
88
+ LightSelectedHover: string;
89
+ DarkSelected: string;
90
+ DarkSelectedHover: string;
91
+ contrastText: string;
92
+ lighter: string;
93
+ light: string;
94
+ main: string;
95
+ dark: string;
96
+ darker: string;
97
+ name: string;
98
+ } | {
99
+ name: string;
100
+ lighter: string;
101
+ light: string;
102
+ main: string;
103
+ dark: string;
104
+ darker: string;
105
+ contrastText: string;
106
+ };
107
+ export declare const orangePreset: {
108
+ LightSelected: string;
109
+ LightSelectedHover: string;
110
+ DarkSelected: string;
111
+ DarkSelectedHover: string;
112
+ contrastText: string;
113
+ lighter: string;
114
+ light: string;
115
+ main: string;
116
+ dark: string;
117
+ darker: string;
118
+ name: string;
119
+ } | {
120
+ name: string;
121
+ lighter: string;
122
+ light: string;
123
+ main: string;
124
+ dark: string;
125
+ darker: string;
126
+ contrastText: string;
127
+ };
128
+ export declare const redPreset: {
129
+ LightSelected: string;
130
+ LightSelectedHover: string;
131
+ DarkSelected: string;
132
+ DarkSelectedHover: string;
133
+ contrastText: string;
134
+ lighter: string;
135
+ light: string;
136
+ main: string;
137
+ dark: string;
138
+ darker: string;
139
+ name: string;
140
+ } | {
141
+ name: string;
142
+ lighter: string;
143
+ light: string;
144
+ main: string;
145
+ dark: string;
146
+ darker: string;
147
+ contrastText: string;
148
+ };
149
+ export declare function getColorPresets(presetsKey: ThemeColorPresets): {
150
+ LightSelected: string;
151
+ LightSelectedHover: string;
152
+ DarkSelected: string;
153
+ DarkSelectedHover: string;
154
+ contrastText: string;
155
+ lighter: string;
156
+ light: string;
157
+ main: string;
158
+ dark: string;
159
+ darker: string;
160
+ name: string;
161
+ } | {
162
+ name: string;
163
+ lighter: string;
164
+ light: string;
165
+ main: string;
166
+ dark: string;
167
+ darker: string;
168
+ contrastText: string;
169
+ };
170
+ export default getColorPresets;
@@ -0,0 +1,24 @@
1
+ import type { Variant } from '@mui/material/styles/createTypography';
2
+ export declare function remToPx(value: string): number;
3
+ export declare function pxToRem(value: number): string;
4
+ export declare function responsiveFontSizes({ sm, md, lg }: {
5
+ sm: number;
6
+ md: number;
7
+ lg: number;
8
+ }): {
9
+ '@media (min-width:600px)': {
10
+ fontSize: string;
11
+ };
12
+ '@media (min-width:900px)': {
13
+ fontSize: string;
14
+ };
15
+ '@media (min-width:1200px)': {
16
+ fontSize: string;
17
+ };
18
+ };
19
+ export declare function getFontValue(variant: Variant): {
20
+ fontSize: number;
21
+ lineHeight: number;
22
+ fontWeight: import("csstype").Property.FontWeight | undefined;
23
+ letterSpacing: import("csstype").Property.LetterSpacing<string | number> | undefined;
24
+ };
@@ -0,0 +1,2 @@
1
+ export * from './getColorPresets';
2
+ export * from './getFontValue';