@atomazing-org/design-system 1.0.24 → 1.0.26
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/dist/index.d.mts +107 -19
- package/dist/index.d.ts +107 -19
- package/dist/index.js +24 -24
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +24 -24
- package/dist/index.mjs.map +1 -1
- package/package.json +64 -64
package/dist/index.d.mts
CHANGED
|
@@ -72,28 +72,124 @@ interface ThemeContextProps {
|
|
|
72
72
|
*/
|
|
73
73
|
type SystemTheme = "light" | "dark" | "unknown";
|
|
74
74
|
|
|
75
|
-
interface
|
|
75
|
+
interface CustomTypographyVariants {
|
|
76
76
|
text_xl_regular: {
|
|
77
77
|
font: string;
|
|
78
78
|
};
|
|
79
79
|
text_lg_regular: {
|
|
80
80
|
font: string;
|
|
81
81
|
};
|
|
82
|
+
text_md_regular: {
|
|
83
|
+
font: string;
|
|
84
|
+
};
|
|
85
|
+
text_sm_regular: {
|
|
86
|
+
font: string;
|
|
87
|
+
};
|
|
88
|
+
text_xs_regular: {
|
|
89
|
+
font: string;
|
|
90
|
+
};
|
|
91
|
+
text_2xs_regular: {
|
|
92
|
+
font: string;
|
|
93
|
+
};
|
|
94
|
+
text_xl_bold: {
|
|
95
|
+
font: string;
|
|
96
|
+
};
|
|
97
|
+
text_lg_bold: {
|
|
98
|
+
font: string;
|
|
99
|
+
};
|
|
100
|
+
text_md_bold: {
|
|
101
|
+
font: string;
|
|
102
|
+
};
|
|
103
|
+
text_sm_bold: {
|
|
104
|
+
font: string;
|
|
105
|
+
};
|
|
106
|
+
text_xs_bold: {
|
|
107
|
+
font: string;
|
|
108
|
+
};
|
|
109
|
+
text_2xs_bold: {
|
|
110
|
+
font: string;
|
|
111
|
+
};
|
|
112
|
+
text_xl_semibold: {
|
|
113
|
+
font: string;
|
|
114
|
+
};
|
|
115
|
+
text_lg_semibold: {
|
|
116
|
+
font: string;
|
|
117
|
+
};
|
|
118
|
+
text_md_semibold: {
|
|
119
|
+
font: string;
|
|
120
|
+
};
|
|
121
|
+
text_sm_semibold: {
|
|
122
|
+
font: string;
|
|
123
|
+
};
|
|
124
|
+
text_xs_semibold: {
|
|
125
|
+
font: string;
|
|
126
|
+
};
|
|
127
|
+
text_2xs_semibold: {
|
|
128
|
+
font: string;
|
|
129
|
+
};
|
|
130
|
+
text_xl_thin: {
|
|
131
|
+
font: string;
|
|
132
|
+
};
|
|
133
|
+
text_lg_thin: {
|
|
134
|
+
font: string;
|
|
135
|
+
};
|
|
136
|
+
text_md_thin: {
|
|
137
|
+
font: string;
|
|
138
|
+
};
|
|
139
|
+
text_sm_thin: {
|
|
140
|
+
font: string;
|
|
141
|
+
};
|
|
142
|
+
text_xs_thin: {
|
|
143
|
+
font: string;
|
|
144
|
+
};
|
|
145
|
+
text_2xs_thin: {
|
|
146
|
+
font: string;
|
|
147
|
+
};
|
|
148
|
+
display_2xl_regular: {
|
|
149
|
+
font: string;
|
|
150
|
+
};
|
|
151
|
+
display_xl_regular: {
|
|
152
|
+
font: string;
|
|
153
|
+
};
|
|
154
|
+
display_lg_regular: {
|
|
155
|
+
font: string;
|
|
156
|
+
};
|
|
157
|
+
display_md_regular: {
|
|
158
|
+
font: string;
|
|
159
|
+
};
|
|
160
|
+
display_sm_regular: {
|
|
161
|
+
font: string;
|
|
162
|
+
};
|
|
163
|
+
display_xs_regular: {
|
|
164
|
+
font: string;
|
|
165
|
+
};
|
|
166
|
+
display_2xl_bold: {
|
|
167
|
+
font: string;
|
|
168
|
+
};
|
|
169
|
+
display_xl_bold: {
|
|
170
|
+
font: string;
|
|
171
|
+
};
|
|
172
|
+
display_lg_bold: {
|
|
173
|
+
font: string;
|
|
174
|
+
};
|
|
175
|
+
display_md_bold: {
|
|
176
|
+
font: string;
|
|
177
|
+
};
|
|
178
|
+
display_sm_bold: {
|
|
179
|
+
font: string;
|
|
180
|
+
};
|
|
181
|
+
display_xs_bold: {
|
|
182
|
+
font: string;
|
|
183
|
+
};
|
|
82
184
|
}
|
|
83
185
|
declare module "@mui/material/styles" {
|
|
84
|
-
interface TypographyVariants {
|
|
85
|
-
text_xl_regular: React.CSSProperties;
|
|
86
|
-
text_lg_regular: React.CSSProperties;
|
|
186
|
+
interface TypographyVariants extends CustomTypographyVariants {
|
|
87
187
|
}
|
|
88
|
-
interface TypographyVariantsOptions {
|
|
89
|
-
text_xl_regular?: React.CSSProperties;
|
|
90
|
-
text_lg_regular?: React.CSSProperties;
|
|
188
|
+
interface TypographyVariantsOptions extends Partial<CustomTypographyVariants> {
|
|
91
189
|
}
|
|
92
190
|
}
|
|
93
191
|
declare module "@mui/material/Typography" {
|
|
94
|
-
interface TypographyPropsVariantOverrides {
|
|
95
|
-
text_xl_regular: true;
|
|
96
|
-
text_lg_regular: true;
|
|
192
|
+
interface TypographyPropsVariantOverrides extends Record<keyof CustomTypographyVariants, true> {
|
|
97
193
|
}
|
|
98
194
|
}
|
|
99
195
|
|
|
@@ -131,14 +227,6 @@ declare const isFontLight: (color: string) => boolean;
|
|
|
131
227
|
*/
|
|
132
228
|
declare const commonComponentProps: Theme["components"];
|
|
133
229
|
|
|
134
|
-
/**
|
|
135
|
-
* Generates a custom MUI theme using a primary color, background color, and color mode.
|
|
136
|
-
*
|
|
137
|
-
* @param primaryColor - The main color used for primary palette.
|
|
138
|
-
* @param backgroundColor - Background color (used as secondary). Defaults to dark blue.
|
|
139
|
-
* @param mode - MUI palette mode ('light' | 'dark'). Defaults to 'dark'.
|
|
140
|
-
* @returns A MUI Theme object.
|
|
141
|
-
*/
|
|
142
230
|
declare const createCustomTheme: (primaryColor: string, backgroundColor?: string, mode?: PaletteMode) => Theme;
|
|
143
231
|
/**
|
|
144
232
|
* A predefined list of named themes based on the `themeConfig` definition.
|
|
@@ -323,4 +411,4 @@ declare const useResponsiveDisplay: (breakpoint?: number) => boolean;
|
|
|
323
411
|
*/
|
|
324
412
|
declare const useSystemTheme: () => SystemTheme;
|
|
325
413
|
|
|
326
|
-
export { type AppSettings, ColorPalette, type DarkModeOptions, DialogBtn, ErrorBoundary, GlobalStyles, Loading, PathName, type SystemTheme, type ThemeContextProps, ThemeProviderWrapper,
|
|
414
|
+
export { type AppSettings, ColorPalette, type CustomTypographyVariants, type DarkModeOptions, DialogBtn, ErrorBoundary, GlobalStyles, Loading, PathName, type SystemTheme, type ThemeContextProps, ThemeProviderWrapper, commonComponentProps, createCustomTheme, displayGreeting, fadeIn, fadeInLeft, getDayIdentifier, getFontColor, installAppAnimation, isDarkMode, isFontLight, isHexColor, logoutAnimation, progressPulse, pulseAnimation, scale, slideIn, slideInBottom, systemInfo, themeConfig, themes, timeAgo, timeAgoFromStart, useResponsiveDisplay, useSystemTheme, useThemeSettings };
|
package/dist/index.d.ts
CHANGED
|
@@ -72,28 +72,124 @@ interface ThemeContextProps {
|
|
|
72
72
|
*/
|
|
73
73
|
type SystemTheme = "light" | "dark" | "unknown";
|
|
74
74
|
|
|
75
|
-
interface
|
|
75
|
+
interface CustomTypographyVariants {
|
|
76
76
|
text_xl_regular: {
|
|
77
77
|
font: string;
|
|
78
78
|
};
|
|
79
79
|
text_lg_regular: {
|
|
80
80
|
font: string;
|
|
81
81
|
};
|
|
82
|
+
text_md_regular: {
|
|
83
|
+
font: string;
|
|
84
|
+
};
|
|
85
|
+
text_sm_regular: {
|
|
86
|
+
font: string;
|
|
87
|
+
};
|
|
88
|
+
text_xs_regular: {
|
|
89
|
+
font: string;
|
|
90
|
+
};
|
|
91
|
+
text_2xs_regular: {
|
|
92
|
+
font: string;
|
|
93
|
+
};
|
|
94
|
+
text_xl_bold: {
|
|
95
|
+
font: string;
|
|
96
|
+
};
|
|
97
|
+
text_lg_bold: {
|
|
98
|
+
font: string;
|
|
99
|
+
};
|
|
100
|
+
text_md_bold: {
|
|
101
|
+
font: string;
|
|
102
|
+
};
|
|
103
|
+
text_sm_bold: {
|
|
104
|
+
font: string;
|
|
105
|
+
};
|
|
106
|
+
text_xs_bold: {
|
|
107
|
+
font: string;
|
|
108
|
+
};
|
|
109
|
+
text_2xs_bold: {
|
|
110
|
+
font: string;
|
|
111
|
+
};
|
|
112
|
+
text_xl_semibold: {
|
|
113
|
+
font: string;
|
|
114
|
+
};
|
|
115
|
+
text_lg_semibold: {
|
|
116
|
+
font: string;
|
|
117
|
+
};
|
|
118
|
+
text_md_semibold: {
|
|
119
|
+
font: string;
|
|
120
|
+
};
|
|
121
|
+
text_sm_semibold: {
|
|
122
|
+
font: string;
|
|
123
|
+
};
|
|
124
|
+
text_xs_semibold: {
|
|
125
|
+
font: string;
|
|
126
|
+
};
|
|
127
|
+
text_2xs_semibold: {
|
|
128
|
+
font: string;
|
|
129
|
+
};
|
|
130
|
+
text_xl_thin: {
|
|
131
|
+
font: string;
|
|
132
|
+
};
|
|
133
|
+
text_lg_thin: {
|
|
134
|
+
font: string;
|
|
135
|
+
};
|
|
136
|
+
text_md_thin: {
|
|
137
|
+
font: string;
|
|
138
|
+
};
|
|
139
|
+
text_sm_thin: {
|
|
140
|
+
font: string;
|
|
141
|
+
};
|
|
142
|
+
text_xs_thin: {
|
|
143
|
+
font: string;
|
|
144
|
+
};
|
|
145
|
+
text_2xs_thin: {
|
|
146
|
+
font: string;
|
|
147
|
+
};
|
|
148
|
+
display_2xl_regular: {
|
|
149
|
+
font: string;
|
|
150
|
+
};
|
|
151
|
+
display_xl_regular: {
|
|
152
|
+
font: string;
|
|
153
|
+
};
|
|
154
|
+
display_lg_regular: {
|
|
155
|
+
font: string;
|
|
156
|
+
};
|
|
157
|
+
display_md_regular: {
|
|
158
|
+
font: string;
|
|
159
|
+
};
|
|
160
|
+
display_sm_regular: {
|
|
161
|
+
font: string;
|
|
162
|
+
};
|
|
163
|
+
display_xs_regular: {
|
|
164
|
+
font: string;
|
|
165
|
+
};
|
|
166
|
+
display_2xl_bold: {
|
|
167
|
+
font: string;
|
|
168
|
+
};
|
|
169
|
+
display_xl_bold: {
|
|
170
|
+
font: string;
|
|
171
|
+
};
|
|
172
|
+
display_lg_bold: {
|
|
173
|
+
font: string;
|
|
174
|
+
};
|
|
175
|
+
display_md_bold: {
|
|
176
|
+
font: string;
|
|
177
|
+
};
|
|
178
|
+
display_sm_bold: {
|
|
179
|
+
font: string;
|
|
180
|
+
};
|
|
181
|
+
display_xs_bold: {
|
|
182
|
+
font: string;
|
|
183
|
+
};
|
|
82
184
|
}
|
|
83
185
|
declare module "@mui/material/styles" {
|
|
84
|
-
interface TypographyVariants {
|
|
85
|
-
text_xl_regular: React.CSSProperties;
|
|
86
|
-
text_lg_regular: React.CSSProperties;
|
|
186
|
+
interface TypographyVariants extends CustomTypographyVariants {
|
|
87
187
|
}
|
|
88
|
-
interface TypographyVariantsOptions {
|
|
89
|
-
text_xl_regular?: React.CSSProperties;
|
|
90
|
-
text_lg_regular?: React.CSSProperties;
|
|
188
|
+
interface TypographyVariantsOptions extends Partial<CustomTypographyVariants> {
|
|
91
189
|
}
|
|
92
190
|
}
|
|
93
191
|
declare module "@mui/material/Typography" {
|
|
94
|
-
interface TypographyPropsVariantOverrides {
|
|
95
|
-
text_xl_regular: true;
|
|
96
|
-
text_lg_regular: true;
|
|
192
|
+
interface TypographyPropsVariantOverrides extends Record<keyof CustomTypographyVariants, true> {
|
|
97
193
|
}
|
|
98
194
|
}
|
|
99
195
|
|
|
@@ -131,14 +227,6 @@ declare const isFontLight: (color: string) => boolean;
|
|
|
131
227
|
*/
|
|
132
228
|
declare const commonComponentProps: Theme["components"];
|
|
133
229
|
|
|
134
|
-
/**
|
|
135
|
-
* Generates a custom MUI theme using a primary color, background color, and color mode.
|
|
136
|
-
*
|
|
137
|
-
* @param primaryColor - The main color used for primary palette.
|
|
138
|
-
* @param backgroundColor - Background color (used as secondary). Defaults to dark blue.
|
|
139
|
-
* @param mode - MUI palette mode ('light' | 'dark'). Defaults to 'dark'.
|
|
140
|
-
* @returns A MUI Theme object.
|
|
141
|
-
*/
|
|
142
230
|
declare const createCustomTheme: (primaryColor: string, backgroundColor?: string, mode?: PaletteMode) => Theme;
|
|
143
231
|
/**
|
|
144
232
|
* A predefined list of named themes based on the `themeConfig` definition.
|
|
@@ -323,4 +411,4 @@ declare const useResponsiveDisplay: (breakpoint?: number) => boolean;
|
|
|
323
411
|
*/
|
|
324
412
|
declare const useSystemTheme: () => SystemTheme;
|
|
325
413
|
|
|
326
|
-
export { type AppSettings, ColorPalette, type DarkModeOptions, DialogBtn, ErrorBoundary, GlobalStyles, Loading, PathName, type SystemTheme, type ThemeContextProps, ThemeProviderWrapper,
|
|
414
|
+
export { type AppSettings, ColorPalette, type CustomTypographyVariants, type DarkModeOptions, DialogBtn, ErrorBoundary, GlobalStyles, Loading, PathName, type SystemTheme, type ThemeContextProps, ThemeProviderWrapper, commonComponentProps, createCustomTheme, displayGreeting, fadeIn, fadeInLeft, getDayIdentifier, getFontColor, installAppAnimation, isDarkMode, isFontLight, isHexColor, logoutAnimation, progressPulse, pulseAnimation, scale, slideIn, slideInBottom, systemInfo, themeConfig, themes, timeAgo, timeAgoFromStart, useResponsiveDisplay, useSystemTheme, useThemeSettings };
|
package/dist/index.js
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
"use strict";var
|
|
1
|
+
"use strict";var ke=Object.create;var b=Object.defineProperty;var Te=Object.getOwnPropertyDescriptor;var we=Object.getOwnPropertyNames;var ve=Object.getPrototypeOf,Me=Object.prototype.hasOwnProperty;var Se=(e,r)=>{for(var t in r)b(e,t,{get:r[t],enumerable:!0})},z=(e,r,t,o)=>{if(r&&typeof r=="object"||typeof r=="function")for(let i of we(r))!Me.call(e,i)&&i!==t&&b(e,i,{get:()=>r[i],enumerable:!(o=Te(r,i))||o.enumerable});return e};var h=(e,r,t)=>(t=e!=null?ke(ve(e)):{},z(r||!e||!e.__esModule?b(t,"default",{value:e,enumerable:!0}):t,e)),Pe=e=>z(b({},"__esModule",{value:!0}),e);var Oe={};Se(Oe,{ColorPalette:()=>s,DialogBtn:()=>N,ErrorBoundary:()=>_,GlobalStyles:()=>ee,Loading:()=>G,PathName:()=>V,ThemeProviderWrapper:()=>_e,commonComponentProps:()=>v,createCustomTheme:()=>y,displayGreeting:()=>me,fadeIn:()=>oe,fadeInLeft:()=>te,getDayIdentifier:()=>fe,getFontColor:()=>x,installAppAnimation:()=>de,isDarkMode:()=>M,isFontLight:()=>J,isHexColor:()=>A,logoutAnimation:()=>le,progressPulse:()=>pe,pulseAnimation:()=>se,scale:()=>ae,slideIn:()=>ie,slideInBottom:()=>ne,systemInfo:()=>xe,themeConfig:()=>w,themes:()=>u,timeAgo:()=>ue,timeAgoFromStart:()=>he,useResponsiveDisplay:()=>ge,useSystemTheme:()=>R,useThemeSettings:()=>j});module.exports=Pe(Oe);var W=h(require("@emotion/styled")),H=require("@mui/material"),N=(0,W.default)(H.Button)`
|
|
2
2
|
padding: 10px 16px;
|
|
3
3
|
border-radius: 16px;
|
|
4
4
|
font-size: 16px;
|
|
5
5
|
margin: 8px;
|
|
6
|
-
`;var Y=
|
|
6
|
+
`;var Y=h(require("react")),L=h(require("@emotion/styled")),O=h(require("@mui/icons-material/ErrorOutlineRounded")),g=require("@mui/material"),p=require("react/jsx-runtime"),_=class extends Y.default.Component{constructor(r){super(r),this.state={hasError:!1}}static getDerivedStateFromError(r){return{hasError:!0,error:r}}componentDidCatch(r,t){console.error("Error:",r),console.error("Error Info:",t)}render(){var o,i,n;let{state:r,props:t}=this;return r.hasError?(0,p.jsxs)(De,{children:[(0,p.jsx)(Re,{children:(0,p.jsx)(g.Box,{children:"\u041E\u0448\u0438\u0431\u043A\u0430.\xA0"})}),(0,p.jsxs)("h3",{children:[(0,p.jsxs)(g.Box,{style:{color:"#ff3131",display:"inline-block"},children:[(0,p.jsx)(O.default,{sx:{verticalAlign:"middle",mb:"4px"}})," ","ERROR:"]})," ",(0,p.jsxs)(g.Box,{translate:"no",children:["[",(o=r.error)==null?void 0:o.name,"] ",(i=r.error)==null?void 0:i.message]}),(0,p.jsxs)(g.Box,{style:{color:"#ff3131",display:"inline-block"},children:[(0,p.jsx)(O.default,{sx:{verticalAlign:"middle",mb:"4px"}})," ","Stack:"]})," ",(0,p.jsxs)(g.Box,{translate:"no",children:["[",(n=r.error)==null?void 0:n.stack,"]"]})]})]}):t.children}},De=L.default.div`
|
|
7
7
|
margin: 0 8vw;
|
|
8
8
|
@media (max-width: 768px) {
|
|
9
9
|
margin: 0;
|
|
10
10
|
}
|
|
11
|
-
`,
|
|
11
|
+
`,Re=L.default.h1`
|
|
12
12
|
margin-top: 32px;
|
|
13
13
|
margin-bottom: 32px;
|
|
14
14
|
font-size: 36px;
|
|
@@ -24,7 +24,7 @@
|
|
|
24
24
|
margin-top: 0;
|
|
25
25
|
margin-bottom: 0;
|
|
26
26
|
}
|
|
27
|
-
`;var
|
|
27
|
+
`;var C=require("react"),U=h(require("@emotion/styled")),k=require("@mui/material"),c=require("react/jsx-runtime"),G=()=>{let[e,r]=(0,C.useState)(!1);return(0,C.useEffect)(()=>{let t=setTimeout(()=>{r(!0)},100);return()=>clearTimeout(t)},[]),(0,c.jsx)(Ee,{children:e&&(0,c.jsxs)(c.Fragment,{children:[(0,c.jsx)(k.CircularProgress,{"aria-label":"loading",size:80,thickness:4}),(0,c.jsx)("h3",{style:{opacity:.8},children:"Loading Page..."})]})})},Ee=(0,U.default)(k.Box)`
|
|
28
28
|
position: absolute;
|
|
29
29
|
top: 50%;
|
|
30
30
|
left: 50%;
|
|
@@ -35,18 +35,18 @@
|
|
|
35
35
|
flex-direction: column;
|
|
36
36
|
text-align: center;
|
|
37
37
|
gap: 8px;
|
|
38
|
-
`;var X=
|
|
38
|
+
`;var X=h(require("@emotion/styled")),V=X.default.code`
|
|
39
39
|
background: #000000c8;
|
|
40
40
|
color: white;
|
|
41
41
|
padding: 4px 6px;
|
|
42
42
|
border-radius: 8px;
|
|
43
|
-
`;var
|
|
43
|
+
`;var T=require("react"),B=(0,T.createContext)(void 0),j=()=>{let e=(0,T.useContext)(B);if(!e)throw new Error("useThemeSettings must be used within ThemeProviderWrapper");return e};var f=require("react"),ye=require("@emotion/react"),be=require("@mui/material/styles");var s={fontDark:"#101727",fontLight:"#f0f0f0",darkMode:"#383838",lightMode:"#ffffff",purple:"#b624ff",red:"#ff3131",orange:"#ff9318",orangeDark:"#ff9500"},w={Lanit:{primaryColor:"#33ccff",secondaryColor:"#f7f7f7"},BPM:{primaryColor:"#203959",secondaryColor:"#ffffff"},Pampa:{primaryColor:"#ffe22e",secondaryColor:"#fafafa"},Hurma:{primaryColor:"#f6883d",secondaryColor:"#ffffff"},"Dark Purple":{primaryColor:s.purple},"Light Purple":{primaryColor:s.purple,secondaryColor:"#edeef6"},"Dark Blue":{primaryColor:"#106cff",secondaryColor:"#090815"},"Light Blue":{primaryColor:"#278ad2",secondaryColor:"#dddaf6"},"Dark Pink":{primaryColor:"#f2369d",secondaryColor:"#191218"},"Light Pink":{primaryColor:"#e5369a",secondaryColor:"#ffe3ff"},"Blush Blossom":{primaryColor:"#EC407A",secondaryColor:"#FCE4EC"},Cheesecake:{primaryColor:"#E14C94",secondaryColor:"#FDF0D5"},"Mystic Coral":{primaryColor:"#ff7b9c",secondaryColor:"#4a2333"},"Dark Orange":{primaryColor:"#FF5631",secondaryColor:"#0D0D0D"},"Light Orange":{primaryColor:"#F26E56",secondaryColor:"#F6F6F6"},Aurora:{primaryColor:"#00e952",secondaryColor:"#011926"}};var A=e=>/^#([\dA-Fa-f]{3}|[\dA-Fa-f]{6})$/.test(e),x=e=>{if(!A(e))return console.error("Invalid hex color provided:",e),s.fontDark;let r=e.slice(1),t=r.length===3?r.split("").map(l=>l+l).join(""):r,o=Number.parseInt(t.slice(0,2),16),i=Number.parseInt(t.slice(2,4),16),n=Number.parseInt(t.slice(4,6),16);return Math.round((o*299+i*587+n*114)/1e3)>128?s.fontDark:s.fontLight},J=e=>x(e)===s.fontLight;var v={MuiTooltip:{defaultProps:{disableInteractive:!0},styleOverrides:{tooltip:({theme:e})=>({color:e.palette.mode==="dark"?"#fff":"#000",backgroundColor:e.palette.mode==="dark"?"#141431dd":"#ededf3dd",backdropFilter:"blur(6px)",WebkitBackdropFilter:"blur(6px)",padding:"8px 16px",borderRadius:e.shape.borderRadius,fontSize:"12px"})}},MuiButton:{styleOverrides:{root:({theme:e})=>({padding:"12px 24px",borderRadius:e.shape.borderRadius}),contained:{boxShadow:"none"}}},MuiSkeleton:{styleOverrides:{root:({theme:e})=>({borderRadius:e.shape.borderRadius})}},MuiSelect:{styleOverrides:{root:({theme:e})=>({borderRadius:e.shape.borderRadius}),select:{display:"flex",justifyContent:"flex-start",alignItems:"center",gap:"4px"}}},MuiDialog:{defaultProps:{slotProps:{paper:{style:{padding:"12px",borderRadius:24,minWidth:"400px"}}}},styleOverrides:{root:{"& .MuiDialog-container":{backdropFilter:"blur(4px)"}}}},MuiAvatar:{styleOverrides:{root:{fontWeight:500,color:"#fff"}}},MuiAlert:{styleOverrides:{root:({theme:e})=>({borderRadius:e.shape.borderRadius})}},MuiTextField:{styleOverrides:{root:({theme:e})=>({"& .MuiInputBase-root":{borderRadius:e.shape.borderRadius}})}},MuiPaper:{styleOverrides:{root:({theme:e})=>({borderRadius:e.shape.borderRadius}),elevation8:({theme:e})=>({borderRadius:e.shape.borderRadius})}},MuiMenuItem:{styleOverrides:{root:({theme:e})=>({borderRadius:e.shape.borderRadius})}},MuiBottomNavigationAction:{styleOverrides:{root:({theme:e})=>({borderRadius:e.shape.borderRadius,padding:"12px",margin:0,maxHeight:"none"})}},MuiIcon:{styleOverrides:{root:{borderRadius:"100%"}}},MuiDialogContent:{styleOverrides:{root:{padding:0}}},MuiSlider:{styleOverrides:{valueLabel:({theme:e})=>({borderRadius:e.shape.borderRadius,padding:"6px 14px",color:e.palette.mode==="dark"?"#fff":"#000",backgroundColor:e.palette.mode==="dark"?"#141431dd":"#ededf3dd","&::before, &::after":{display:"none"}})}},MuiCircularProgress:{styleOverrides:{circle:{strokeLinecap:"round"}}},MuiTab:{styleOverrides:{root:({theme:e})=>({borderRadius:e.shape.borderRadius})}},MuiAccordion:{styleOverrides:{root:{"&::before":{display:"none"}}}}};var K=require("@mui/material");var Q={defaultProps:{variantMapping:{text_xl_regular:"p",text_lg_regular:"p",text_md_regular:"p",text_sm_regular:"p",text_xs_regular:"p",text_2xs_regular:"p",text_xl_bold:"p",text_lg_bold:"p",text_md_bold:"p",text_sm_bold:"p",text_xs_bold:"p",text_2xs_bold:"p",text_xl_semibold:"p",text_lg_semibold:"p",text_md_semibold:"p",text_sm_semibold:"p",text_xs_semibold:"p",text_2xs_semibold:"p",text_xl_thin:"p",text_lg_thin:"p",text_md_thin:"p",text_sm_thin:"p",text_xs_thin:"p",text_2xs_thin:"p",display_2xl_regular:"h1",display_xl_regular:"h2",display_lg_regular:"h3",display_md_regular:"h4",display_sm_regular:"h5",display_xs_regular:"h6",display_2xl_bold:"h1",display_xl_bold:"h2",display_lg_bold:"h3",display_md_bold:"h4",display_sm_bold:"h5",display_xs_bold:"h6"}}},q={text_xl_regular:{font:"400 20px/30px inherit inherit"},text_lg_regular:{font:"400 18px/28px inherit inherit"},text_md_regular:{font:"400 16px/24px inherit inherit"},text_sm_regular:{font:"400 14px/20px inherit inherit"},text_xs_regular:{font:"400 12px/18px inherit inherit"},text_2xs_regular:{font:"400 10px/14px inherit inherit"},text_xl_bold:{font:"700 20px/30px inherit inherit"},text_lg_bold:{font:"700 18px/28px inherit inherit"},text_md_bold:{font:"700 16px/24px inherit inherit"},text_sm_bold:{font:"700 14px/20px inherit inherit"},text_xs_bold:{font:"700 12px/18px inherit inherit"},text_2xs_bold:{font:"700 10px/14px inherit inherit"},text_xl_semibold:{font:"600 20px/30px inherit inherit"},text_lg_semibold:{font:"600 18px/28px inherit inherit"},text_md_semibold:{font:"600 16px/24px inherit inherit"},text_sm_semibold:{font:"600 14px/20px inherit inherit"},text_xs_semibold:{font:"600 12px/18px inherit inherit"},text_2xs_semibold:{font:"600 10px/14px inherit inherit"},text_xl_thin:{font:"100 20px/30px inherit inherit"},text_lg_thin:{font:"100 18px/28px inherit inherit"},text_md_thin:{font:"100 16px/24px inherit inherit"},text_sm_thin:{font:"100 14px/20px inherit inherit"},text_xs_thin:{font:"100 12px/18px inherit inherit"},text_2xs_thin:{font:"100 10px/14px inherit inherit"},display_2xl_regular:{font:"400 72px/90px inherit inherit"},display_xl_regular:{font:"400 60px/72px inherit inherit"},display_lg_regular:{font:"400 48px/60px inherit inherit"},display_md_regular:{font:"400 36px/44px inherit inherit"},display_sm_regular:{font:"400 30px/38px inherit inherit"},display_xs_regular:{font:"400 24px/32px inherit inherit"},display_2xl_bold:{font:"700 72px/90px inherit inherit"},display_xl_bold:{font:"700 60px/72px inherit inherit"},display_lg_bold:{font:"700 48px/60px inherit inherit"},display_md_bold:{font:"700 36px/44px inherit inherit"},display_sm_bold:{font:"700 30px/38px inherit inherit"},display_xs_bold:{font:"700 24px/32px inherit inherit"}};var y=(e,r="#232e58",t="dark")=>(0,K.createTheme)({palette:{primary:{main:e},secondary:{main:r},warning:{main:t==="dark"?s.orange:s.orangeDark},error:{main:s.red},mode:t},components:{...v,MuiTypography:Q},typography:q,shape:{borderRadius:24}}),u=Object.entries(w).map(([e,r])=>({name:e,MuiTheme:y(r.primaryColor,r.secondaryColor)})),M=(e,r,t)=>{switch(e){case"light":return!1;case"dark":return!0;case"system":return r==="dark";case"auto":return x(t)===s.fontLight;default:return!1}};var $=require("react"),S=require("@emotion/react"),Z=require("@mui/material/styles");var re=require("react/jsx-runtime"),ee=()=>{let e=(0,Z.useTheme)(),r=e.palette.mode==="dark",t=e.palette.primary.main,o=e.palette.secondary.main,i=(0,$.useMemo)(()=>x(t),[t]),n=(0,$.useMemo)(()=>x(o),[o]);return(0,re.jsx)(S.Global,{styles:S.css`
|
|
44
44
|
* {
|
|
45
45
|
font-family: "Poppins", sans-serif !important;
|
|
46
46
|
-webkit-tap-highlight-color: transparent;
|
|
47
47
|
&::selection {
|
|
48
|
-
background-color: ${`${
|
|
49
|
-
color: ${
|
|
48
|
+
background-color: ${`${t}e1`};
|
|
49
|
+
color: ${i};
|
|
50
50
|
}
|
|
51
51
|
}
|
|
52
52
|
|
|
@@ -56,7 +56,7 @@
|
|
|
56
56
|
line-height: 1.5;
|
|
57
57
|
font-weight: 400;
|
|
58
58
|
color-scheme: ${r?"dark":"light"};
|
|
59
|
-
color: ${
|
|
59
|
+
color: ${n};
|
|
60
60
|
font-synthesis: none;
|
|
61
61
|
text-rendering: optimizeLegibility;
|
|
62
62
|
-webkit-font-smoothing: antialiased;
|
|
@@ -71,25 +71,25 @@
|
|
|
71
71
|
margin: 0;
|
|
72
72
|
height: 100%;
|
|
73
73
|
touch-action: manipulation;
|
|
74
|
-
background: ${
|
|
74
|
+
background: ${o};
|
|
75
75
|
background-attachment: fixed;
|
|
76
76
|
background-size: cover;
|
|
77
77
|
transition: 0.3s background;
|
|
78
78
|
|
|
79
79
|
::-webkit-scrollbar {
|
|
80
80
|
width: 8px;
|
|
81
|
-
background-color: ${
|
|
81
|
+
background-color: ${o};
|
|
82
82
|
}
|
|
83
83
|
::-webkit-scrollbar-thumb {
|
|
84
|
-
background-color: ${
|
|
84
|
+
background-color: ${t};
|
|
85
85
|
border-radius: 64px;
|
|
86
86
|
}
|
|
87
87
|
::-webkit-scrollbar-thumb:hover {
|
|
88
|
-
background-color: ${`${
|
|
88
|
+
background-color: ${`${t}d8`};
|
|
89
89
|
}
|
|
90
90
|
::-webkit-scrollbar-track {
|
|
91
91
|
border-radius: 64px;
|
|
92
|
-
background-color: ${
|
|
92
|
+
background-color: ${o};
|
|
93
93
|
}
|
|
94
94
|
}
|
|
95
95
|
|
|
@@ -161,7 +161,7 @@
|
|
|
161
161
|
margin-top: 3px;
|
|
162
162
|
}
|
|
163
163
|
}
|
|
164
|
-
`})};var
|
|
164
|
+
`})};var m=require("@emotion/react"),te=m.keyframes`
|
|
165
165
|
from {
|
|
166
166
|
opacity: 0;
|
|
167
167
|
transform: translateX(-40px);
|
|
@@ -170,35 +170,35 @@
|
|
|
170
170
|
opacity: 1;
|
|
171
171
|
transform: translateX(0);
|
|
172
172
|
}
|
|
173
|
-
`,
|
|
173
|
+
`,oe=m.keyframes`
|
|
174
174
|
from {
|
|
175
175
|
opacity: 0;
|
|
176
176
|
}
|
|
177
177
|
to {
|
|
178
178
|
opacity: 1;
|
|
179
179
|
}
|
|
180
|
-
`,
|
|
180
|
+
`,ie=m.keyframes`
|
|
181
181
|
from {
|
|
182
182
|
transform: translateX(-100%);
|
|
183
183
|
}
|
|
184
184
|
to {
|
|
185
185
|
transform: translateX(0);
|
|
186
186
|
}
|
|
187
|
-
`,
|
|
187
|
+
`,ne=m.keyframes`
|
|
188
188
|
from {
|
|
189
189
|
transform: translateY(100%);
|
|
190
190
|
}
|
|
191
191
|
to {
|
|
192
192
|
transform: translateY(0);
|
|
193
193
|
}
|
|
194
|
-
`,
|
|
194
|
+
`,ae=m.keyframes`
|
|
195
195
|
from {
|
|
196
196
|
transform: scale(0);
|
|
197
197
|
}
|
|
198
198
|
to {
|
|
199
199
|
transform: scale(1);
|
|
200
200
|
}
|
|
201
|
-
`,
|
|
201
|
+
`,se=(e,r=12)=>m.keyframes`
|
|
202
202
|
0% {
|
|
203
203
|
transform: scale(0.95);
|
|
204
204
|
box-shadow: 0 0 0 0 ${e}b2;
|
|
@@ -211,7 +211,7 @@
|
|
|
211
211
|
transform: scale(0.95);
|
|
212
212
|
box-shadow: 0 0 0 0 ${e}00;
|
|
213
213
|
}
|
|
214
|
-
`,
|
|
214
|
+
`,pe=e=>m.keyframes`
|
|
215
215
|
0% {
|
|
216
216
|
filter: none;
|
|
217
217
|
}
|
|
@@ -221,7 +221,7 @@
|
|
|
221
221
|
100% {
|
|
222
222
|
filter: none;
|
|
223
223
|
}
|
|
224
|
-
`,
|
|
224
|
+
`,le=m.keyframes`
|
|
225
225
|
0% {
|
|
226
226
|
transform: scale(1);
|
|
227
227
|
opacity: 1;
|
|
@@ -234,7 +234,7 @@
|
|
|
234
234
|
transform: scale(1);
|
|
235
235
|
opacity: 1;
|
|
236
236
|
}
|
|
237
|
-
`,
|
|
237
|
+
`,de=m.keyframes`
|
|
238
238
|
0% {
|
|
239
239
|
transform: translateY(0);
|
|
240
240
|
}
|
|
@@ -250,5 +250,5 @@
|
|
|
250
250
|
100% {
|
|
251
251
|
transform: translateY(0);
|
|
252
252
|
}
|
|
253
|
-
`;var
|
|
253
|
+
`;var me=()=>{let r=new Date().getHours(),t;return r<12&&r>=5?t="\u0414\u043E\u0431\u0440\u043E\u0435 \u0443\u0442\u0440\u043E,":r<18&&r>12?t="\u0414\u043E\u0431\u0440\u044B\u0439 \u0434\u0435\u043D\u044C,":t="\u0414\u043E\u0431\u0440\u044B\u0439 \u0432\u0435\u0447\u0435\u0440,",t};var fe=e=>{let r=e.getFullYear(),t=String(e.getMonth()+1).padStart(2,"0"),o=String(e.getDate()).padStart(2,"0");return`${r}-${t}-${o}`};var{userAgent:ce}=globalThis.navigator,Fe=()=>{let e=ce.toLowerCase();return e.includes("windows nt")?"Windows":e.includes("iphone")||e.includes("ipad")||e.includes("ipod")?"iOS":e.includes("mac")?"macOS":e.includes("android")?"Android":e.includes("linux")?"Linux":"Unknown"},Ie=()=>{let e=ce.toLowerCase();return e.includes("edg")?"Edge":e.includes("chrome")?"Chrome":e.includes("firefox")?"Firefox":e.includes("safari")?"Safari":"Unknown"},xe={os:Fe(),browser:Ie()};var ue=(e,r=navigator.language||"en-US")=>{let t=new Date;e=new Date(e);let o=Math.floor((t.getTime()-e.getTime())/1e3),i=new Intl.RelativeTimeFormat(r,{numeric:"auto"});if(o<60)return i.format(-o,"second");if(o<3600){let a=Math.floor(o/60);return i.format(-a,"minute")}if(o<86400){let a=Math.floor(o/3600);return i.format(-a,"hour")}let n=Math.floor(o/86400);return i.format(-n,"day")},he=(e,r=navigator.language||"en-US")=>{let t=new Date;e=new Date(e);let o=(e.getTime()-t.getTime())/1e3,i=Math.floor(o/(60*60)),n=Math.floor((o-60*60*i)/60),a=Math.floor(o-60*60*i-60*n),l=new Intl.RelativeTimeFormat(r,{numeric:"auto"});if(n===0&&a<60)return l.format(a,"second");if(i===0&&n<60)return l.format(n,"minute");if(i<24){let I=`${new Intl.RelativeTimeFormat(r,{numeric:"auto"}).format(i,"hour")}`,d=` ${new Intl.RelativeTimeFormat(r,{localeMatcher:"lookup",numeric:"always",style:"long"}).format(n,"minute")}`.replace(/^\D+/,"");return`${I} ${d}`}let F=Math.floor(a/86400);return l.format(F,"day")};var P=require("react"),ge=(e=768)=>{let[r,t]=(0,P.useState)(!1);return(0,P.useEffect)(()=>{let o=()=>{t(window.innerWidth<e)};o();let i=()=>o();return window.addEventListener("resize",i),()=>{window.removeEventListener("resize",i)}},[e]),r};var D=require("react"),R=()=>{let[e,r]=(0,D.useState)("unknown");return(0,D.useEffect)(()=>{let t=i=>{r(i.matches?"dark":"light")},o=globalThis.matchMedia("(prefers-color-scheme: dark)");return r(o.matches?"dark":"light"),o.addEventListener("change",t),()=>{o.removeEventListener("change",t)}},[]),e};var E=require("react/jsx-runtime"),_e=({children:e})=>{let r=R(),[t,o]=(0,f.useState)(()=>{let d=localStorage.getItem("appSettings");return d&&JSON.parse(d).theme||"system"}),[i,n]=(0,f.useState)(()=>{let d=localStorage.getItem("appSettings");return d&&JSON.parse(d).darkMode||"auto"});(0,f.useEffect)(()=>{localStorage.setItem("appSettings",JSON.stringify({theme:t,darkMode:i}))},[t,i]);let a=(0,f.useMemo)(()=>{var d;return r==="unknown"?u[0].MuiTheme:t==="system"?r==="dark"?u[0].MuiTheme:u[1].MuiTheme:((d=u.find(Ce=>Ce.name===t))==null?void 0:d.MuiTheme)||u[0].MuiTheme},[r,t]),l=(0,f.useMemo)(()=>M(i,r,a.palette.secondary.main)?"dark":"light",[i,r,a]),F=(0,f.useMemo)(()=>y(a.palette.primary.main,a.palette.secondary.main,l),[a,l]),I=(0,f.useMemo)(()=>({darkMode:l==="dark"}),[l]);return(0,E.jsx)(B.Provider,{value:{theme:t,darkMode:i,setTheme:o,setDarkMode:n},children:(0,E.jsx)(be.ThemeProvider,{theme:F,children:(0,E.jsx)(ye.ThemeProvider,{theme:I,children:e})})})};0&&(module.exports={ColorPalette,DialogBtn,ErrorBoundary,GlobalStyles,Loading,PathName,ThemeProviderWrapper,commonComponentProps,createCustomTheme,displayGreeting,fadeIn,fadeInLeft,getDayIdentifier,getFontColor,installAppAnimation,isDarkMode,isFontLight,isHexColor,logoutAnimation,progressPulse,pulseAnimation,scale,slideIn,slideInBottom,systemInfo,themeConfig,themes,timeAgo,timeAgoFromStart,useResponsiveDisplay,useSystemTheme,useThemeSettings});
|
|
254
254
|
//# sourceMappingURL=index.js.map
|