@mui/docs 6.0.0-alpha.1 → 6.0.0-alpha.10
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/CHANGELOG.md +462 -4
- package/CodeCopy/CodeCopy.d.ts +20 -0
- package/CodeCopy/CodeCopy.js +172 -0
- package/CodeCopy/CodeCopyButton.d.ts +5 -0
- package/CodeCopy/CodeCopyButton.js +41 -0
- package/CodeCopy/index.d.ts +3 -0
- package/CodeCopy/index.js +3 -0
- package/CodeCopy/package.json +6 -0
- package/CodeCopy/useClipboardCopy.d.ts +4 -0
- package/CodeCopy/useClipboardCopy.js +21 -0
- package/ComponentLinkHeader/ComponentLinkHeader.d.ts +9 -0
- package/ComponentLinkHeader/ComponentLinkHeader.js +179 -0
- package/ComponentLinkHeader/index.d.ts +2 -0
- package/ComponentLinkHeader/index.js +2 -0
- package/ComponentLinkHeader/package.json +6 -0
- package/HighlightedCode/HighlightedCode.d.ts +14 -0
- package/HighlightedCode/HighlightedCode.js +68 -0
- package/HighlightedCode/index.d.ts +1 -0
- package/HighlightedCode/index.js +1 -0
- package/HighlightedCode/package.json +6 -0
- package/InfoCard/InfoCard.d.ts +0 -1
- package/InfoCard/InfoCard.js +45 -44
- package/Link/Link.js +40 -38
- package/MarkdownElement/MarkdownElement.d.ts +6 -0
- package/MarkdownElement/MarkdownElement.js +825 -0
- package/MarkdownElement/index.d.ts +1 -0
- package/MarkdownElement/index.js +1 -0
- package/MarkdownElement/package.json +6 -0
- package/NProgressBar/NProgressBar.js +6 -7
- package/SectionTitle/SectionTitle.d.ts +7 -0
- package/SectionTitle/SectionTitle.js +30 -0
- package/SectionTitle/index.d.ts +1 -0
- package/SectionTitle/index.js +1 -0
- package/SectionTitle/package.json +6 -0
- package/branding/brandingTheme.js +569 -369
- package/node/CodeCopy/CodeCopy.js +188 -0
- package/node/CodeCopy/CodeCopyButton.js +50 -0
- package/node/CodeCopy/index.js +40 -0
- package/node/CodeCopy/useClipboardCopy.js +30 -0
- package/node/ComponentLinkHeader/ComponentLinkHeader.js +189 -0
- package/node/ComponentLinkHeader/index.js +24 -0
- package/node/HighlightedCode/HighlightedCode.js +77 -0
- package/node/HighlightedCode/index.js +16 -0
- package/node/InfoCard/InfoCard.js +45 -44
- package/node/Link/Link.js +43 -40
- package/node/MarkdownElement/MarkdownElement.js +837 -0
- package/node/MarkdownElement/index.js +16 -0
- package/node/NProgressBar/NProgressBar.js +6 -7
- package/node/SectionTitle/SectionTitle.js +38 -0
- package/node/SectionTitle/index.js +16 -0
- package/node/branding/brandingTheme.js +569 -369
- package/node/svgIcons/AdobeXDIcon.js +22 -0
- package/node/svgIcons/BundleSizeIcon.js +22 -0
- package/node/svgIcons/FigmaIcon.js +31 -0
- package/node/svgIcons/FileDownload.js +3 -3
- package/node/svgIcons/JavaScript.js +3 -3
- package/node/svgIcons/MaterialDesignIcon.js +27 -0
- package/node/svgIcons/SketchIcon.js +36 -0
- package/node/svgIcons/TypeScript.js +3 -3
- package/node/svgIcons/W3CIcon.js +24 -0
- package/node/translations/translations.json +4 -2
- package/package.json +6 -4
- package/svgIcons/AdobeXDIcon.d.ts +4 -0
- package/svgIcons/AdobeXDIcon.js +14 -0
- package/svgIcons/BundleSizeIcon.d.ts +4 -0
- package/svgIcons/BundleSizeIcon.js +14 -0
- package/svgIcons/FigmaIcon.d.ts +4 -0
- package/svgIcons/FigmaIcon.js +23 -0
- package/svgIcons/FileDownload.d.ts +7 -0
- package/svgIcons/FileDownload.js +3 -3
- package/svgIcons/JavaScript.d.ts +7 -0
- package/svgIcons/JavaScript.js +3 -3
- package/svgIcons/MaterialDesignIcon.d.ts +4 -0
- package/svgIcons/MaterialDesignIcon.js +19 -0
- package/svgIcons/SketchIcon.d.ts +4 -0
- package/svgIcons/SketchIcon.js +28 -0
- package/svgIcons/TypeScript.d.ts +7 -0
- package/svgIcons/TypeScript.js +3 -3
- package/svgIcons/W3CIcon.d.ts +4 -0
- package/svgIcons/W3CIcon.js +16 -0
- package/translations/translations.json +4 -2
- package/tsconfig.build.tsbuildinfo +1 -1
- package/legacy/DocsProvider/DocsProvider.js +0 -25
- package/legacy/DocsProvider/index.js +0 -1
- package/legacy/InfoCard/InfoCard.js +0 -86
- package/legacy/InfoCard/index.js +0 -1
- package/legacy/Link/Link.js +0 -101
- package/legacy/Link/index.js +0 -1
- package/legacy/NProgressBar/NProgressBar.js +0 -80
- package/legacy/NProgressBar/index.js +0 -1
- package/legacy/branding/BrandingProvider.js +0 -17
- package/legacy/branding/brandingTheme.js +0 -1168
- package/legacy/branding/index.js +0 -2
- package/legacy/i18n/i18n.js +0 -105
- package/legacy/i18n/index.js +0 -1
- package/legacy/svgIcons/FileDownload.js +0 -14
- package/legacy/svgIcons/JavaScript.js +0 -14
- package/legacy/svgIcons/TypeScript.js +0 -14
- package/legacy/translations/index.js +0 -4
|
@@ -7,7 +7,6 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
7
7
|
exports.getMetaThemeColor = exports.getDesignTokens = exports.error = exports.brandingLightTheme = exports.brandingDarkTheme = exports.blueDark = exports.blue = void 0;
|
|
8
8
|
exports.getThemedComponents = getThemedComponents;
|
|
9
9
|
exports.warning = exports.success = exports.grey = void 0;
|
|
10
|
-
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
|
|
11
10
|
var _ArrowDropDownRounded = _interopRequireDefault(require("@mui/icons-material/ArrowDropDownRounded"));
|
|
12
11
|
var _styles = require("@mui/material/styles");
|
|
13
12
|
// TODO: enable this once types conflict is fixed
|
|
@@ -104,57 +103,75 @@ const getMetaThemeColor = mode => {
|
|
|
104
103
|
};
|
|
105
104
|
exports.getMetaThemeColor = getMetaThemeColor;
|
|
106
105
|
const getDesignTokens = mode => ({
|
|
107
|
-
palette:
|
|
108
|
-
primary:
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
106
|
+
palette: {
|
|
107
|
+
primary: {
|
|
108
|
+
...blue,
|
|
109
|
+
...(mode === 'dark' && {
|
|
110
|
+
main: blue[400]
|
|
111
|
+
})
|
|
112
|
+
},
|
|
113
|
+
secondary: {
|
|
114
|
+
...grey,
|
|
115
|
+
...(mode === 'light' && {
|
|
116
|
+
main: blueDark[100],
|
|
117
|
+
contrastText: blueDark[600]
|
|
118
|
+
}),
|
|
119
|
+
...(mode === 'dark' && {
|
|
120
|
+
main: blueDark[700],
|
|
121
|
+
contrastText: blueDark[600]
|
|
122
|
+
})
|
|
123
|
+
},
|
|
118
124
|
divider: mode === 'dark' ? (0, _styles.alpha)(blueDark[500], 0.3) : grey[100],
|
|
119
125
|
primaryDark: blueDark,
|
|
120
|
-
mode
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
126
|
+
mode,
|
|
127
|
+
...(mode === 'dark' && {
|
|
128
|
+
background: {
|
|
129
|
+
default: blueDark[900],
|
|
130
|
+
paper: (0, _styles.alpha)(blueDark[800], 0.8)
|
|
131
|
+
}
|
|
132
|
+
}),
|
|
127
133
|
common: {
|
|
128
134
|
black: 'hsl(200, 10%, 4%)'
|
|
129
135
|
},
|
|
130
|
-
text:
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
136
|
+
text: {
|
|
137
|
+
...(mode === 'light' && {
|
|
138
|
+
primary: grey[900],
|
|
139
|
+
secondary: grey[800],
|
|
140
|
+
tertiary: grey[700]
|
|
141
|
+
}),
|
|
142
|
+
...(mode === 'dark' && {
|
|
143
|
+
primary: '#fff',
|
|
144
|
+
secondary: grey[400],
|
|
145
|
+
tertiary: grey[500]
|
|
146
|
+
})
|
|
147
|
+
},
|
|
148
|
+
grey: {
|
|
149
|
+
...grey,
|
|
150
|
+
...(mode === 'light' && {
|
|
151
|
+
main: grey[100],
|
|
152
|
+
contrastText: grey[600]
|
|
153
|
+
}),
|
|
154
|
+
...(mode === 'dark' && {
|
|
155
|
+
main: grey[700],
|
|
156
|
+
contrastText: grey[600]
|
|
157
|
+
})
|
|
158
|
+
},
|
|
146
159
|
error,
|
|
147
|
-
success:
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
160
|
+
success: {
|
|
161
|
+
...success,
|
|
162
|
+
...(mode === 'dark' && {
|
|
163
|
+
main: success[600]
|
|
164
|
+
}),
|
|
165
|
+
...(mode === 'light' && {
|
|
166
|
+
main: success[700]
|
|
167
|
+
})
|
|
168
|
+
},
|
|
152
169
|
warning,
|
|
153
170
|
gradients: {
|
|
154
171
|
radioSubtle: mode === 'dark' ? `radial-gradient(100% 100% at 100% 100%, transparent 0, ${(0, _styles.alpha)(blue[900], 0.3)} 300%)` : `radial-gradient(100% 90% at 50% 0, transparent 0, ${(0, _styles.alpha)(blue[100], 0.3)} 300%)`,
|
|
155
|
-
linearSubtle: mode === '
|
|
172
|
+
linearSubtle: mode === 'dark' ? `linear-gradient(0deg, ${(0, _styles.alpha)(blue[900], 0.1)}, ${(0, _styles.alpha)(blueDark[900], 0.5)})` : `linear-gradient(0deg, ${(0, _styles.alpha)(blue[50], 0.4)}, ${(0, _styles.alpha)(grey[50], 0.1)})`
|
|
156
173
|
}
|
|
157
|
-
}
|
|
174
|
+
},
|
|
158
175
|
shape: {
|
|
159
176
|
borderRadius: 12
|
|
160
177
|
},
|
|
@@ -176,15 +193,16 @@ const getDesignTokens = mode => ({
|
|
|
176
193
|
fontFamilySystem: systemFont.join(','),
|
|
177
194
|
fontWeightSemiBold: 600,
|
|
178
195
|
fontWeightExtraBold: 800,
|
|
179
|
-
h1:
|
|
196
|
+
h1: {
|
|
180
197
|
fontFamily: ['"General Sans"', ...systemFont].join(','),
|
|
181
198
|
fontSize: 'clamp(2.5rem, 1.125rem + 3.5vw, 3.5em)',
|
|
182
199
|
fontWeight: 600,
|
|
183
200
|
lineHeight: 78 / 70,
|
|
184
|
-
letterSpacing: -0.2
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
201
|
+
letterSpacing: -0.2,
|
|
202
|
+
...(mode === 'light' && {
|
|
203
|
+
color: blueDark[900]
|
|
204
|
+
})
|
|
205
|
+
},
|
|
188
206
|
h2: {
|
|
189
207
|
fontFamily: ['"General Sans"', ...systemFont].join(','),
|
|
190
208
|
fontSize: 'clamp(1.5rem, 0.9643rem + 1.4286vw, 2.25rem)',
|
|
@@ -228,20 +246,17 @@ const getDesignTokens = mode => ({
|
|
|
228
246
|
},
|
|
229
247
|
body1: {
|
|
230
248
|
fontSize: defaultTheme.typography.pxToRem(16),
|
|
231
|
-
// 16px
|
|
232
249
|
lineHeight: 24 / 16,
|
|
233
250
|
letterSpacing: 0
|
|
234
251
|
},
|
|
235
252
|
body2: {
|
|
236
253
|
fontSize: defaultTheme.typography.pxToRem(14),
|
|
237
|
-
// 14px
|
|
238
254
|
lineHeight: 21 / 14,
|
|
239
255
|
letterSpacing: 0
|
|
240
256
|
},
|
|
241
257
|
caption: {
|
|
242
258
|
display: 'inline-block',
|
|
243
259
|
fontSize: defaultTheme.typography.pxToRem(12),
|
|
244
|
-
// 12px
|
|
245
260
|
lineHeight: 18 / 12,
|
|
246
261
|
letterSpacing: 0,
|
|
247
262
|
fontWeight: 700
|
|
@@ -314,29 +329,95 @@ function getThemedComponents() {
|
|
|
314
329
|
MuiAlert: {
|
|
315
330
|
styleOverrides: {
|
|
316
331
|
root: {
|
|
317
|
-
padding: '
|
|
332
|
+
padding: '16px',
|
|
333
|
+
gap: '12px',
|
|
334
|
+
fontSize: '1rem',
|
|
335
|
+
'& * ul': {
|
|
336
|
+
paddingLeft: '24px !important',
|
|
337
|
+
marginBottom: '0 !important'
|
|
338
|
+
},
|
|
339
|
+
// !important is used here to override the anchor tag color coming from MarkdownElement
|
|
340
|
+
'& .MuiAlert-icon': {
|
|
341
|
+
margin: 0,
|
|
342
|
+
marginTop: '2px',
|
|
343
|
+
padding: 0
|
|
344
|
+
},
|
|
345
|
+
'& .MuiAlert-message': {
|
|
346
|
+
padding: 0
|
|
347
|
+
}
|
|
348
|
+
},
|
|
349
|
+
icon: {
|
|
350
|
+
paddingTop: 10,
|
|
351
|
+
paddingBottom: 0
|
|
318
352
|
},
|
|
319
353
|
standardWarning: ({
|
|
320
354
|
theme
|
|
321
|
-
}) => [
|
|
355
|
+
}) => [
|
|
356
|
+
// same styles from the MarkdownElement callout
|
|
357
|
+
{
|
|
322
358
|
backgroundColor: (0, _styles.alpha)(theme.palette.warning[50], 0.5),
|
|
323
359
|
color: (theme.vars || theme).palette.grey[900],
|
|
324
360
|
border: '1px solid',
|
|
325
|
-
borderColor: (0, _styles.alpha)(theme.palette.warning[
|
|
361
|
+
borderColor: (0, _styles.alpha)(theme.palette.warning[700], 0.15),
|
|
326
362
|
'& .MuiAlert-icon': {
|
|
327
|
-
color: (theme.vars || theme).palette.warning[
|
|
363
|
+
color: (theme.vars || theme).palette.warning[600]
|
|
364
|
+
},
|
|
365
|
+
'& * a': {
|
|
366
|
+
// !important is used here to override the anchor tag color coming from MarkdownElement
|
|
367
|
+
color: `${(theme.vars || theme).palette.warning[900]} !important`,
|
|
368
|
+
textDecorationColor: `${(0, _styles.alpha)(theme.palette.warning.main, 0.4)} !important`,
|
|
369
|
+
'&:hover': {
|
|
370
|
+
textDecorationColor: `${(theme.vars || theme).palette.warning[900]} !important`
|
|
371
|
+
}
|
|
328
372
|
}
|
|
329
373
|
}, theme.applyDarkStyles({
|
|
330
|
-
backgroundColor: (0, _styles.alpha)(theme.palette.warning[700], 0.
|
|
374
|
+
backgroundColor: (0, _styles.alpha)(theme.palette.warning[700], 0.12),
|
|
331
375
|
color: (theme.vars || theme).palette.warning[50],
|
|
332
376
|
'& .MuiAlert-icon': {
|
|
333
|
-
color: (theme.vars || theme).palette.warning[
|
|
377
|
+
color: (theme.vars || theme).palette.warning[400]
|
|
378
|
+
},
|
|
379
|
+
'& * a': {
|
|
380
|
+
color: `${(theme.vars || theme).palette.warning[100]} !important`,
|
|
381
|
+
textDecorationColor: `${(0, _styles.alpha)(theme.palette.warning[600], 0.4)} !important`,
|
|
382
|
+
'&:hover': {
|
|
383
|
+
textDecorationColor: `${(theme.vars || theme).palette.warning[600]} !important`
|
|
384
|
+
}
|
|
334
385
|
}
|
|
335
386
|
})],
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
387
|
+
standardSuccess: ({
|
|
388
|
+
theme
|
|
389
|
+
}) => [
|
|
390
|
+
// same styles from the MarkdownElement callout
|
|
391
|
+
{
|
|
392
|
+
backgroundColor: (0, _styles.alpha)(theme.palette.success[50], 0.5),
|
|
393
|
+
color: (theme.vars || theme).palette.success[900],
|
|
394
|
+
border: `1px solid ${(theme.vars || theme).palette.success[100]}`,
|
|
395
|
+
'& .MuiAlert-icon': {
|
|
396
|
+
color: (theme.vars || theme).palette.success[600]
|
|
397
|
+
},
|
|
398
|
+
'& * a': {
|
|
399
|
+
// !important is used here to override the anchor tag color coming from MarkdownElement
|
|
400
|
+
color: `${(theme.vars || theme).palette.success[900]} !important`,
|
|
401
|
+
textDecorationColor: `${(0, _styles.alpha)(theme.palette.success.main, 0.4)} !important`,
|
|
402
|
+
'&:hover': {
|
|
403
|
+
textDecorationColor: `${(theme.vars || theme).palette.success[900]} !important`
|
|
404
|
+
}
|
|
405
|
+
}
|
|
406
|
+
}, theme.applyDarkStyles({
|
|
407
|
+
backgroundColor: (0, _styles.alpha)(theme.palette.success[700], 0.12),
|
|
408
|
+
color: (theme.vars || theme).palette.success[50],
|
|
409
|
+
borderColor: (0, _styles.alpha)(theme.palette.success[400], 0.1),
|
|
410
|
+
'& .MuiAlert-icon': {
|
|
411
|
+
color: (theme.vars || theme).palette.success[500]
|
|
412
|
+
},
|
|
413
|
+
'& * a': {
|
|
414
|
+
color: `${(theme.vars || theme).palette.success[100]} !important`,
|
|
415
|
+
textDecorationColor: `${(0, _styles.alpha)(theme.palette.success[600], 0.4)} !important`,
|
|
416
|
+
'&:hover': {
|
|
417
|
+
textDecorationColor: `${(theme.vars || theme).palette.success[600]} !important`
|
|
418
|
+
}
|
|
419
|
+
}
|
|
420
|
+
})]
|
|
340
421
|
}
|
|
341
422
|
},
|
|
342
423
|
MuiButtonBase: {
|
|
@@ -364,107 +445,135 @@ function getThemedComponents() {
|
|
|
364
445
|
root: ({
|
|
365
446
|
theme,
|
|
366
447
|
ownerState
|
|
367
|
-
}) => (
|
|
368
|
-
transition: 'all 120ms ease-in'
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
marginLeft: -1
|
|
403
|
-
},
|
|
404
|
-
'& .MuiButton-endIcon': {
|
|
405
|
-
transition: '0.15s',
|
|
406
|
-
marginLeft: 4
|
|
407
|
-
},
|
|
408
|
-
'&:hover': {
|
|
448
|
+
}) => ({
|
|
449
|
+
transition: 'all 120ms ease-in',
|
|
450
|
+
...(ownerState.size === 'large' && {
|
|
451
|
+
...theme.typography.body1,
|
|
452
|
+
lineHeight: 21 / 16,
|
|
453
|
+
padding: theme.spacing('8px', '10px', '10px', '12px'),
|
|
454
|
+
fontWeight: theme.typography.fontWeightMedium,
|
|
455
|
+
borderRadius: 10,
|
|
456
|
+
'& > span': {
|
|
457
|
+
transition: '0.2s',
|
|
458
|
+
marginLeft: 4
|
|
459
|
+
},
|
|
460
|
+
'&:hover > span': {
|
|
461
|
+
transform: 'translateX(2px)'
|
|
462
|
+
}
|
|
463
|
+
}),
|
|
464
|
+
...(ownerState.size === 'medium' && {
|
|
465
|
+
fontSize: defaultTheme.typography.pxToRem(15),
|
|
466
|
+
padding: theme.spacing('8px', '12px', '8px', '14px'),
|
|
467
|
+
fontWeight: theme.typography.fontWeightMedium,
|
|
468
|
+
borderRadius: 8,
|
|
469
|
+
'& > span': {
|
|
470
|
+
transition: '0.2s',
|
|
471
|
+
marginLeft: 4
|
|
472
|
+
},
|
|
473
|
+
'&:hover > span': {
|
|
474
|
+
transform: 'translateX(2px)'
|
|
475
|
+
}
|
|
476
|
+
}),
|
|
477
|
+
...(ownerState.size === 'small' && {
|
|
478
|
+
padding: '6px 8px',
|
|
479
|
+
fontFamily: theme.typography.fontFamily,
|
|
480
|
+
fontSize: defaultTheme.typography.pxToRem(13),
|
|
481
|
+
fontWeight: theme.typography.fontWeightMedium,
|
|
482
|
+
borderRadius: 8,
|
|
409
483
|
'& .MuiButton-startIcon': {
|
|
410
|
-
|
|
484
|
+
transition: '0.15s',
|
|
485
|
+
marginRight: 4,
|
|
486
|
+
marginLeft: -1
|
|
411
487
|
},
|
|
412
488
|
'& .MuiButton-endIcon': {
|
|
413
|
-
|
|
489
|
+
transition: '0.15s',
|
|
490
|
+
marginLeft: 4
|
|
491
|
+
},
|
|
492
|
+
'&:hover': {
|
|
493
|
+
'& .MuiButton-startIcon': {
|
|
494
|
+
transform: 'translateX(-2px)'
|
|
495
|
+
},
|
|
496
|
+
'& .MuiButton-endIcon': {
|
|
497
|
+
transform: 'translateX(2px)'
|
|
498
|
+
}
|
|
414
499
|
}
|
|
415
|
-
}
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
backgroundColor: (theme.vars || theme).palette.primary[
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
500
|
+
}),
|
|
501
|
+
...(ownerState.variant === 'outlined' && ownerState.color === 'secondary' && {
|
|
502
|
+
color: (theme.vars || theme).palette.text.primary,
|
|
503
|
+
backgroundColor: (0, _styles.alpha)(theme.palette.primaryDark[50], 0.1),
|
|
504
|
+
borderColor: (theme.vars || theme).palette.primaryDark[100],
|
|
505
|
+
boxShadow: `#FFF 0 1px 0 inset, ${(0, _styles.alpha)(theme.palette.grey[200], 0.4)} 0 -1px 0 inset, ${(0, _styles.alpha)(theme.palette.grey[200], 0.5)} 0 1px 2px 0`,
|
|
506
|
+
'&:hover': {
|
|
507
|
+
backgroundColor: (theme.vars || theme).palette.grey[50]
|
|
508
|
+
},
|
|
509
|
+
...theme.applyDarkStyles({
|
|
510
|
+
color: (theme.vars || theme).palette.primaryDark[100],
|
|
511
|
+
borderColor: (0, _styles.alpha)(theme.palette.primaryDark[600], 0.5),
|
|
512
|
+
backgroundColor: (0, _styles.alpha)(theme.palette.primaryDark[700], 0.2),
|
|
513
|
+
boxShadow: `${(0, _styles.alpha)(theme.palette.primaryDark[600], 0.3)} 0 1px 0 inset, ${(theme.vars || theme).palette.common.black} 0 -1px 0 inset, ${(theme.vars || theme).palette.common.black} 0 1px 2px 0`,
|
|
514
|
+
'&:hover': {
|
|
515
|
+
backgroundColor: (theme.vars || theme).palette.primaryDark[700],
|
|
516
|
+
borderColor: (theme.vars || theme).palette.primaryDark[600]
|
|
517
|
+
}
|
|
518
|
+
})
|
|
519
|
+
}),
|
|
520
|
+
...(ownerState.variant === 'outlined' && ownerState.color === 'primary' && {
|
|
521
|
+
color: (theme.vars || theme).palette.primary[600],
|
|
522
|
+
backgroundColor: (0, _styles.alpha)(theme.palette.primary[50], 0.2),
|
|
523
|
+
borderColor: (theme.vars || theme).palette.primary[100],
|
|
524
|
+
boxShadow: `${(0, _styles.alpha)(theme.palette.primary[50], 0.8)} 0 2px 0 inset, ${(0, _styles.alpha)(theme.palette.primary[100], 0.4)} 0 -2px 0 inset, ${(0, _styles.alpha)(theme.palette.primary[100], 0.5)} 0 1px 2px 0`,
|
|
525
|
+
'&:hover': {
|
|
526
|
+
backgroundColor: (theme.vars || theme).palette.primary[50],
|
|
527
|
+
borderColor: (theme.vars || theme).palette.primary[200]
|
|
528
|
+
},
|
|
529
|
+
...theme.applyDarkStyles({
|
|
530
|
+
color: (theme.vars || theme).palette.primary[200],
|
|
531
|
+
borderColor: (0, _styles.alpha)(theme.palette.primary[900], 0.7),
|
|
532
|
+
backgroundColor: (0, _styles.alpha)(theme.palette.primary[900], 0.2),
|
|
533
|
+
boxShadow: `${(0, _styles.alpha)(theme.palette.primary[900], 0.2)} 0 2px 0 inset, ${(theme.vars || theme).palette.common.black} 0 -2px 0 inset, ${(theme.vars || theme).palette.common.black} 0 1px 2px 0`,
|
|
534
|
+
'&:hover': {
|
|
535
|
+
backgroundColor: (theme.vars || theme).palette.primary[900],
|
|
536
|
+
borderColor: (theme.vars || theme).palette.primary[700]
|
|
537
|
+
}
|
|
538
|
+
})
|
|
539
|
+
}),
|
|
540
|
+
...(ownerState.variant === 'contained' && ownerState.color === 'primary' && {
|
|
541
|
+
color: '#fff',
|
|
542
|
+
textShadow: `0 1px 1px ${(0, _styles.alpha)(theme.palette.common.black, 0.6)}`,
|
|
543
|
+
backgroundColor: (theme.vars || theme).palette.primary[500],
|
|
544
|
+
backgroundImage: `linear-gradient(180deg, ${(0, _styles.alpha)(theme.palette.primary[500], 0.6)} 0%, ${theme.palette.primary[600]} 100%)`,
|
|
545
|
+
boxShadow: `${theme.palette.primary[400]} 0 2px 0 inset, ${theme.palette.primary[700]} 0 -2px 0 inset, ${(0, _styles.alpha)(theme.palette.common.black, 0.1)} 0 2px 4px 0`,
|
|
546
|
+
'&:hover': {
|
|
547
|
+
backgroundColor: (theme.vars || theme).palette.primary[700]
|
|
548
|
+
},
|
|
549
|
+
'&:active': {
|
|
550
|
+
backgroundColor: (theme.vars || theme).palette.primaryDark[700]
|
|
551
|
+
}
|
|
552
|
+
}),
|
|
553
|
+
...(ownerState.variant === 'text' && ownerState.color === 'secondary' && {
|
|
554
|
+
color: (theme.vars || theme).palette.text.secondary,
|
|
555
|
+
'&:hover': {
|
|
556
|
+
backgroundColor: (theme.vars || theme).palette.grey[50]
|
|
557
|
+
},
|
|
558
|
+
'&:active': {
|
|
559
|
+
backgroundColor: (theme.vars || theme).palette.grey[200]
|
|
560
|
+
},
|
|
561
|
+
...theme.applyDarkStyles({
|
|
562
|
+
'&:hover': {
|
|
563
|
+
backgroundColor: (0, _styles.alpha)(theme.palette.primaryDark[700], 0.5)
|
|
564
|
+
},
|
|
565
|
+
'&:active': {
|
|
566
|
+
backgroundColor: (theme.vars || theme).palette.primaryDark[700]
|
|
567
|
+
}
|
|
568
|
+
})
|
|
569
|
+
}),
|
|
570
|
+
...(ownerState.variant === 'text' && ownerState.color === 'primary' && {
|
|
571
|
+
color: (theme.vars || theme).palette.primary[600],
|
|
572
|
+
...theme.applyDarkStyles({
|
|
573
|
+
color: (theme.vars || theme).palette.primary[300]
|
|
574
|
+
})
|
|
575
|
+
})
|
|
576
|
+
})
|
|
468
577
|
},
|
|
469
578
|
variants: [{
|
|
470
579
|
// @ts-ignore internal repo module augmentation issue
|
|
@@ -582,23 +691,48 @@ function getThemedComponents() {
|
|
|
582
691
|
},
|
|
583
692
|
style: ({
|
|
584
693
|
theme
|
|
585
|
-
}) => (
|
|
694
|
+
}) => ({
|
|
586
695
|
marginBottom: 1,
|
|
587
696
|
fontSize: theme.typography.pxToRem(14),
|
|
588
697
|
fontWeight: theme.typography.fontWeightBold,
|
|
589
698
|
color: (theme.vars || theme).palette.primary[600],
|
|
590
699
|
'&:hover': {
|
|
591
700
|
backgroundColor: (theme.vars || theme).palette.primary[50]
|
|
592
|
-
}
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
|
|
701
|
+
},
|
|
702
|
+
...theme.applyDarkStyles({
|
|
703
|
+
color: (theme.vars || theme).palette.primary[300],
|
|
704
|
+
'&:hover': {
|
|
705
|
+
backgroundColor: (0, _styles.alpha)(theme.palette.primary[800], 0.3)
|
|
706
|
+
}
|
|
707
|
+
})
|
|
708
|
+
})
|
|
599
709
|
}]
|
|
600
710
|
},
|
|
601
711
|
MuiIconButton: {
|
|
712
|
+
styleOverrides: {
|
|
713
|
+
root: ({
|
|
714
|
+
theme,
|
|
715
|
+
ownerState
|
|
716
|
+
}) => ({
|
|
717
|
+
borderRadius: theme.shape.borderRadius,
|
|
718
|
+
transition: 'all 100ms ease-in',
|
|
719
|
+
'&:hover': {
|
|
720
|
+
borderColor: (theme.vars || theme).palette.grey[300],
|
|
721
|
+
background: (theme.vars || theme).palette.grey[50],
|
|
722
|
+
...theme.applyDarkStyles({
|
|
723
|
+
borderColor: (theme.vars || theme).palette.primaryDark[600],
|
|
724
|
+
background: (0, _styles.alpha)(theme.palette.primaryDark[700], 0.8)
|
|
725
|
+
})
|
|
726
|
+
},
|
|
727
|
+
...(ownerState.size === 'small' && {
|
|
728
|
+
height: 32,
|
|
729
|
+
width: 32,
|
|
730
|
+
'& .MuiSvgIcon-root': {
|
|
731
|
+
fontSize: defaultTheme.typography.pxToRem(18)
|
|
732
|
+
}
|
|
733
|
+
})
|
|
734
|
+
})
|
|
735
|
+
},
|
|
602
736
|
variants: [{
|
|
603
737
|
props: {
|
|
604
738
|
color: 'primary'
|
|
@@ -606,14 +740,10 @@ function getThemedComponents() {
|
|
|
606
740
|
style: ({
|
|
607
741
|
theme
|
|
608
742
|
}) => [{
|
|
609
|
-
height: 34,
|
|
610
|
-
width: 34,
|
|
611
|
-
border: `1px solid`,
|
|
612
|
-
borderRadius: theme.shape.borderRadius,
|
|
613
743
|
color: (theme.vars || theme).palette.primary.main,
|
|
614
744
|
backgroundColor: (0, _styles.alpha)(theme.palette.primaryDark[50], 0.1),
|
|
615
|
-
|
|
616
|
-
boxShadow:
|
|
745
|
+
border: `1px solid ${(theme.vars || theme).palette.primaryDark[100]}`,
|
|
746
|
+
boxShadow: `#FFF 0 1px 0 inset, ${(0, _styles.alpha)(theme.palette.grey[200], 0.4)} 0 -1px 0 inset, ${(0, _styles.alpha)(theme.palette.grey[200], 0.5)} 0 1px 2px 0`,
|
|
617
747
|
'&:hover': {
|
|
618
748
|
borderColor: (theme.vars || theme).palette.grey[300],
|
|
619
749
|
background: (theme.vars || theme).palette.grey[50]
|
|
@@ -622,10 +752,10 @@ function getThemedComponents() {
|
|
|
622
752
|
color: (theme.vars || theme).palette.primary[300],
|
|
623
753
|
borderColor: (0, _styles.alpha)(theme.palette.primaryDark[600], 0.5),
|
|
624
754
|
backgroundColor: (0, _styles.alpha)(theme.palette.primaryDark[700], 0.2),
|
|
625
|
-
boxShadow: `${(0, _styles.alpha)(theme.palette.primaryDark[600], 0.
|
|
755
|
+
boxShadow: `${(0, _styles.alpha)(theme.palette.primaryDark[600], 0.3)} 0 1px 0 inset, ${(theme.vars || theme).palette.common.black} 0 -1px 0 inset, ${(theme.vars || theme).palette.common.black} 0 1px 2px 0`,
|
|
626
756
|
'&:hover': {
|
|
627
|
-
borderColor: (theme.vars || theme).palette.primaryDark[
|
|
628
|
-
background: (0, _styles.alpha)(theme.palette.primaryDark[700], 0.
|
|
757
|
+
borderColor: (theme.vars || theme).palette.primaryDark[600],
|
|
758
|
+
background: (0, _styles.alpha)(theme.palette.primaryDark[700], 0.8)
|
|
629
759
|
}
|
|
630
760
|
})]
|
|
631
761
|
}, {
|
|
@@ -635,27 +765,22 @@ function getThemedComponents() {
|
|
|
635
765
|
style: ({
|
|
636
766
|
theme
|
|
637
767
|
}) => [{
|
|
638
|
-
|
|
639
|
-
width: 34,
|
|
640
|
-
color: (theme.vars || theme).palette.text.tertiary,
|
|
641
|
-
borderRadius: theme.shape.borderRadius,
|
|
642
|
-
border: `1px solid`,
|
|
768
|
+
color: (theme.vars || theme).palette.text.secondary,
|
|
643
769
|
backgroundColor: (0, _styles.alpha)(theme.palette.primaryDark[50], 0.1),
|
|
644
|
-
|
|
645
|
-
boxShadow:
|
|
770
|
+
border: `1px solid ${(theme.vars || theme).palette.primaryDark[100]}`,
|
|
771
|
+
boxShadow: `#FFF 0 1px 0 inset, ${(0, _styles.alpha)(theme.palette.grey[200], 0.4)} 0 -1px 0 inset, ${(0, _styles.alpha)(theme.palette.grey[200], 0.5)} 0 1px 2px 0`,
|
|
646
772
|
'&:hover': {
|
|
647
|
-
color: (theme.vars || theme).palette.primary
|
|
773
|
+
color: (theme.vars || theme).palette.text.primary,
|
|
648
774
|
borderColor: (theme.vars || theme).palette.grey[300],
|
|
649
775
|
background: (theme.vars || theme).palette.grey[50]
|
|
650
776
|
}
|
|
651
777
|
}, theme.applyDarkStyles({
|
|
652
778
|
borderColor: (0, _styles.alpha)(theme.palette.primaryDark[600], 0.5),
|
|
653
779
|
backgroundColor: (0, _styles.alpha)(theme.palette.primaryDark[700], 0.2),
|
|
654
|
-
boxShadow: `${(0, _styles.alpha)(theme.palette.primaryDark[600], 0.
|
|
780
|
+
boxShadow: `${(0, _styles.alpha)(theme.palette.primaryDark[600], 0.3)} 0 1px 0 inset, ${(theme.vars || theme).palette.common.black} 0 -1px 0 inset, ${(theme.vars || theme).palette.common.black} 0 1px 2px 0`,
|
|
655
781
|
'&:hover': {
|
|
656
|
-
|
|
657
|
-
|
|
658
|
-
background: (0, _styles.alpha)(theme.palette.primaryDark[700], 0.4)
|
|
782
|
+
borderColor: (theme.vars || theme).palette.primaryDark[600],
|
|
783
|
+
background: (0, _styles.alpha)(theme.palette.primaryDark[700], 0.8)
|
|
659
784
|
}
|
|
660
785
|
})]
|
|
661
786
|
}]
|
|
@@ -665,17 +790,29 @@ function getThemedComponents() {
|
|
|
665
790
|
paper: ({
|
|
666
791
|
theme
|
|
667
792
|
}) => [{
|
|
793
|
+
padding: '6px',
|
|
668
794
|
minWidth: 160,
|
|
669
795
|
color: (theme.vars || theme).palette.text.secondary,
|
|
670
796
|
backgroundImage: 'none',
|
|
671
797
|
border: '1px solid',
|
|
672
798
|
backgroundColor: (theme.vars || theme).palette.background.paper,
|
|
673
799
|
borderColor: (theme.vars || theme).palette.grey[200],
|
|
800
|
+
'& .MuiMenu-list': {
|
|
801
|
+
display: 'flex',
|
|
802
|
+
flexDirection: 'column',
|
|
803
|
+
gap: '2px',
|
|
804
|
+
'& .MuiDivider-root': {
|
|
805
|
+
margin: '4px -8px 4px -8px'
|
|
806
|
+
}
|
|
807
|
+
},
|
|
674
808
|
'& .MuiMenuItem-root': {
|
|
809
|
+
padding: '6px 8px',
|
|
810
|
+
borderRadius: '6px',
|
|
675
811
|
fontSize: theme.typography.pxToRem(14),
|
|
676
|
-
fontWeight:
|
|
677
|
-
'&:hover
|
|
678
|
-
backgroundColor: (theme.vars || theme).palette.grey[
|
|
812
|
+
fontWeight: theme.typography.fontWeightMedium,
|
|
813
|
+
'&:hover': {
|
|
814
|
+
backgroundColor: (theme.vars || theme).palette.grey[100],
|
|
815
|
+
color: (theme.vars || theme).palette.text.primary
|
|
679
816
|
},
|
|
680
817
|
'&:focus-visible': {
|
|
681
818
|
outline: 'none'
|
|
@@ -690,11 +827,11 @@ function getThemedComponents() {
|
|
|
690
827
|
backgroundColor: (theme.vars || theme).palette.primaryDark[900],
|
|
691
828
|
borderColor: (theme.vars || theme).palette.primaryDark[700],
|
|
692
829
|
'& .MuiMenuItem-root': {
|
|
693
|
-
'&:hover
|
|
830
|
+
'&:hover': {
|
|
694
831
|
backgroundColor: (theme.vars || theme).palette.primaryDark[700]
|
|
695
832
|
},
|
|
696
833
|
'&.Mui-selected': {
|
|
697
|
-
color: (theme.vars || theme).palette.primary[
|
|
834
|
+
color: (theme.vars || theme).palette.primary[200],
|
|
698
835
|
backgroundColor: (0, _styles.alpha)(theme.palette.primary[900], 0.4)
|
|
699
836
|
}
|
|
700
837
|
}
|
|
@@ -705,22 +842,21 @@ function getThemedComponents() {
|
|
|
705
842
|
styleOverrides: {
|
|
706
843
|
paper: ({
|
|
707
844
|
theme
|
|
708
|
-
}) => (
|
|
709
|
-
boxShadow: '0px 4px 20px rgba(170, 180, 190, 0.3)'
|
|
710
|
-
|
|
711
|
-
|
|
712
|
-
|
|
845
|
+
}) => ({
|
|
846
|
+
boxShadow: '0px 4px 20px rgba(170, 180, 190, 0.3)',
|
|
847
|
+
...theme.applyDarkStyles({
|
|
848
|
+
boxShadow: '0px 4px 20px rgba(0, 0, 0, 0.5)'
|
|
849
|
+
})
|
|
850
|
+
})
|
|
713
851
|
}
|
|
714
852
|
},
|
|
715
853
|
MuiDivider: {
|
|
716
854
|
styleOverrides: {
|
|
717
855
|
root: ({
|
|
718
856
|
theme
|
|
719
|
-
}) => (
|
|
720
|
-
borderColor: (theme.vars || theme).palette.
|
|
721
|
-
}
|
|
722
|
-
borderColor: (0, _styles.alpha)(theme.palette.primaryDark[700], 0.8)
|
|
723
|
-
}))
|
|
857
|
+
}) => ({
|
|
858
|
+
borderColor: (theme.vars || theme).palette.divider
|
|
859
|
+
})
|
|
724
860
|
}
|
|
725
861
|
},
|
|
726
862
|
MuiLink: {
|
|
@@ -773,107 +909,131 @@ function getThemedComponents() {
|
|
|
773
909
|
variant
|
|
774
910
|
},
|
|
775
911
|
theme
|
|
776
|
-
}) => (
|
|
912
|
+
}) => ({
|
|
777
913
|
fontWeight: theme.typography.fontWeightSemiBold,
|
|
778
|
-
paddingBottom: 0.2
|
|
779
|
-
|
|
780
|
-
|
|
781
|
-
|
|
782
|
-
|
|
783
|
-
'&:hover': {
|
|
784
|
-
backgroundColor: (theme.vars || theme).palette.grey[100],
|
|
785
|
-
color: (theme.vars || theme).palette.grey[900]
|
|
786
|
-
}
|
|
787
|
-
}, theme.applyDarkStyles({
|
|
788
|
-
backgroundColor: (0, _styles.alpha)(theme.palette.primaryDark[700], 0.4),
|
|
789
|
-
color: (theme.vars || theme).palette.grey[300],
|
|
790
|
-
borderColor: (0, _styles.alpha)(theme.palette.primaryDark[500], 0.5),
|
|
791
|
-
'&:hover': {
|
|
792
|
-
color: (theme.vars || theme).palette.grey[300],
|
|
793
|
-
backgroundColor: (theme.vars || theme).palette.primaryDark[700]
|
|
794
|
-
}
|
|
795
|
-
})), variant === 'outlined' && color === 'info' && (0, _extends2.default)({
|
|
796
|
-
backgroundColor: (0, _styles.alpha)(theme.palette.grey[50], 0.5),
|
|
797
|
-
color: (theme.vars || theme).palette.grey[900],
|
|
798
|
-
borderColor: (theme.vars || theme).palette.grey[200]
|
|
799
|
-
}, theme.applyDarkStyles({
|
|
800
|
-
color: (theme.vars || theme).palette.grey[300],
|
|
801
|
-
backgroundColor: (0, _styles.alpha)(theme.palette.primaryDark[700], 0.5),
|
|
802
|
-
borderColor: (theme.vars || theme).palette.primaryDark[600]
|
|
803
|
-
})), variant === 'outlined' && color === 'primary' && (0, _extends2.default)({
|
|
804
|
-
borderColor: (theme.vars || theme).palette.primary[100],
|
|
805
|
-
backgroundColor: (theme.vars || theme).palette.primary[50]
|
|
806
|
-
}, theme.applyDarkStyles({
|
|
807
|
-
color: (theme.vars || theme).palette.primary[300],
|
|
808
|
-
borderColor: (0, _styles.alpha)(theme.palette.primary[500], 0.2),
|
|
809
|
-
backgroundColor: (0, _styles.alpha)(theme.palette.primary[700], 0.2)
|
|
810
|
-
})), variant === 'outlined' && color === 'success' && (0, _extends2.default)({
|
|
811
|
-
borderColor: (theme.vars || theme).palette.success[100],
|
|
812
|
-
backgroundColor: (theme.vars || theme).palette.success[50],
|
|
813
|
-
color: (theme.vars || theme).palette.success[900]
|
|
814
|
-
}, theme.applyDarkStyles({
|
|
815
|
-
color: (theme.vars || theme).palette.success[300],
|
|
816
|
-
borderColor: (0, _styles.alpha)(theme.palette.success[300], 0.2),
|
|
817
|
-
background: (0, _styles.alpha)(theme.palette.success[800], 0.2)
|
|
818
|
-
})), variant === 'filled' && (0, _extends2.default)({}, color === 'default' && (0, _extends2.default)({
|
|
819
|
-
border: '1px solid transparent',
|
|
820
|
-
color: (theme.vars || theme).palette.primary[700],
|
|
821
|
-
backgroundColor: (0, _styles.alpha)(theme.palette.primary[100], 0.5),
|
|
822
|
-
'&:hover': {
|
|
823
|
-
backgroundColor: (theme.vars || theme).palette.primary[100]
|
|
824
|
-
}
|
|
825
|
-
}, theme.applyDarkStyles({
|
|
826
|
-
color: '#fff',
|
|
827
|
-
backgroundColor: (0, _styles.alpha)(theme.palette.primaryDark[500], 0.8),
|
|
828
|
-
'&:hover': {
|
|
829
|
-
backgroundColor: (theme.vars || theme).palette.primaryDark[600]
|
|
830
|
-
}
|
|
831
|
-
})), color === 'primary' && (0, _extends2.default)({
|
|
832
|
-
color: (theme.vars || theme).palette.primary[600],
|
|
833
|
-
backgroundColor: (0, _styles.alpha)(theme.palette.primary[100], 0.4),
|
|
834
|
-
'&:hover': {
|
|
835
|
-
backgroundColor: (theme.vars || theme).palette.primary[100]
|
|
836
|
-
},
|
|
837
|
-
'& .MuiChip-deleteIcon': {
|
|
838
|
-
color: (theme.vars || theme).palette.primary[600],
|
|
839
|
-
'&:hover': {
|
|
840
|
-
color: (theme.vars || theme).palette.primary[700]
|
|
841
|
-
}
|
|
842
|
-
},
|
|
843
|
-
'&.Mui-focusVisible': {
|
|
844
|
-
backgroundColor: (theme.vars || theme).palette.primary[200]
|
|
845
|
-
}
|
|
846
|
-
}, theme.applyDarkStyles({
|
|
847
|
-
color: (theme.vars || theme).palette.primary[100],
|
|
848
|
-
backgroundColor: (0, _styles.alpha)(theme.palette.primary[800], 0.5),
|
|
849
|
-
'&:hover': {
|
|
850
|
-
backgroundColor: (0, _styles.alpha)(theme.palette.primary[900], 0.5)
|
|
851
|
-
},
|
|
852
|
-
'& .MuiChip-deleteIcon': {
|
|
853
|
-
color: (theme.vars || theme).palette.primary[100],
|
|
914
|
+
paddingBottom: 0.2,
|
|
915
|
+
...(variant === 'outlined' && color === 'default' && {
|
|
916
|
+
backgroundColor: (0, _styles.alpha)(theme.palette.grey[50], 0.5),
|
|
917
|
+
color: (theme.vars || theme).palette.grey[900],
|
|
918
|
+
borderColor: (theme.vars || theme).palette.grey[200],
|
|
854
919
|
'&:hover': {
|
|
855
|
-
|
|
856
|
-
|
|
857
|
-
|
|
858
|
-
|
|
859
|
-
|
|
860
|
-
|
|
861
|
-
|
|
862
|
-
|
|
863
|
-
|
|
864
|
-
|
|
865
|
-
|
|
866
|
-
|
|
867
|
-
|
|
868
|
-
color
|
|
869
|
-
|
|
870
|
-
|
|
871
|
-
|
|
872
|
-
|
|
873
|
-
|
|
874
|
-
|
|
875
|
-
|
|
876
|
-
|
|
920
|
+
backgroundColor: (theme.vars || theme).palette.grey[100],
|
|
921
|
+
color: (theme.vars || theme).palette.grey[900]
|
|
922
|
+
},
|
|
923
|
+
...theme.applyDarkStyles({
|
|
924
|
+
backgroundColor: (0, _styles.alpha)(theme.palette.primaryDark[700], 0.4),
|
|
925
|
+
color: (theme.vars || theme).palette.grey[300],
|
|
926
|
+
borderColor: (0, _styles.alpha)(theme.palette.primaryDark[500], 0.5),
|
|
927
|
+
'&:hover': {
|
|
928
|
+
color: (theme.vars || theme).palette.grey[300],
|
|
929
|
+
backgroundColor: (theme.vars || theme).palette.primaryDark[700]
|
|
930
|
+
}
|
|
931
|
+
})
|
|
932
|
+
}),
|
|
933
|
+
...(variant === 'outlined' && color === 'info' && {
|
|
934
|
+
backgroundColor: (0, _styles.alpha)(theme.palette.grey[50], 0.5),
|
|
935
|
+
color: (theme.vars || theme).palette.grey[900],
|
|
936
|
+
borderColor: (theme.vars || theme).palette.grey[200],
|
|
937
|
+
...theme.applyDarkStyles({
|
|
938
|
+
color: (theme.vars || theme).palette.grey[300],
|
|
939
|
+
backgroundColor: (0, _styles.alpha)(theme.palette.primaryDark[700], 0.5),
|
|
940
|
+
borderColor: (theme.vars || theme).palette.primaryDark[600]
|
|
941
|
+
})
|
|
942
|
+
}),
|
|
943
|
+
...(variant === 'outlined' && color === 'primary' && {
|
|
944
|
+
borderColor: (theme.vars || theme).palette.primary[100],
|
|
945
|
+
backgroundColor: (0, _styles.alpha)(theme.palette.primary[100], 0.2),
|
|
946
|
+
...theme.applyDarkStyles({
|
|
947
|
+
color: (theme.vars || theme).palette.primary[300],
|
|
948
|
+
borderColor: (0, _styles.alpha)(theme.palette.primary[500], 0.2),
|
|
949
|
+
backgroundColor: (0, _styles.alpha)(theme.palette.primary[700], 0.2)
|
|
950
|
+
})
|
|
951
|
+
}),
|
|
952
|
+
...(variant === 'outlined' && color === 'success' && {
|
|
953
|
+
borderColor: (theme.vars || theme).palette.success[100],
|
|
954
|
+
backgroundColor: (theme.vars || theme).palette.success[50],
|
|
955
|
+
color: (theme.vars || theme).palette.success[900],
|
|
956
|
+
...theme.applyDarkStyles({
|
|
957
|
+
color: (theme.vars || theme).palette.success[300],
|
|
958
|
+
borderColor: (0, _styles.alpha)(theme.palette.success[300], 0.2),
|
|
959
|
+
background: (0, _styles.alpha)(theme.palette.success[800], 0.2)
|
|
960
|
+
})
|
|
961
|
+
}),
|
|
962
|
+
...(variant === 'filled' && {
|
|
963
|
+
...(color === 'default' && {
|
|
964
|
+
border: '1px solid transparent',
|
|
965
|
+
color: (theme.vars || theme).palette.primary[700],
|
|
966
|
+
backgroundColor: (0, _styles.alpha)(theme.palette.primary[100], 0.5),
|
|
967
|
+
'&:hover': {
|
|
968
|
+
backgroundColor: (theme.vars || theme).palette.primary[100]
|
|
969
|
+
},
|
|
970
|
+
...theme.applyDarkStyles({
|
|
971
|
+
color: '#fff',
|
|
972
|
+
backgroundColor: (0, _styles.alpha)(theme.palette.primaryDark[500], 0.8),
|
|
973
|
+
'&:hover': {
|
|
974
|
+
backgroundColor: (theme.vars || theme).palette.primaryDark[600]
|
|
975
|
+
}
|
|
976
|
+
})
|
|
977
|
+
}),
|
|
978
|
+
...(color === 'primary' && {
|
|
979
|
+
color: (theme.vars || theme).palette.primary[600],
|
|
980
|
+
backgroundColor: (0, _styles.alpha)(theme.palette.primary[100], 0.4),
|
|
981
|
+
'&:hover': {
|
|
982
|
+
backgroundColor: (theme.vars || theme).palette.primary[100]
|
|
983
|
+
},
|
|
984
|
+
'& .MuiChip-deleteIcon': {
|
|
985
|
+
color: (theme.vars || theme).palette.primary[600],
|
|
986
|
+
'&:hover': {
|
|
987
|
+
color: (theme.vars || theme).palette.primary[700]
|
|
988
|
+
}
|
|
989
|
+
},
|
|
990
|
+
'&.Mui-focusVisible': {
|
|
991
|
+
backgroundColor: (theme.vars || theme).palette.primary[200]
|
|
992
|
+
},
|
|
993
|
+
...theme.applyDarkStyles({
|
|
994
|
+
color: (theme.vars || theme).palette.primary[100],
|
|
995
|
+
backgroundColor: (0, _styles.alpha)(theme.palette.primary[800], 0.5),
|
|
996
|
+
'&:hover': {
|
|
997
|
+
backgroundColor: (0, _styles.alpha)(theme.palette.primary[900], 0.5)
|
|
998
|
+
},
|
|
999
|
+
'& .MuiChip-deleteIcon': {
|
|
1000
|
+
color: (theme.vars || theme).palette.primary[100],
|
|
1001
|
+
'&:hover': {
|
|
1002
|
+
color: (theme.vars || theme).palette.primary[50]
|
|
1003
|
+
}
|
|
1004
|
+
}
|
|
1005
|
+
})
|
|
1006
|
+
})
|
|
1007
|
+
}),
|
|
1008
|
+
// for labelling product in the search
|
|
1009
|
+
// @ts-ignore internal repo module augmentation issue
|
|
1010
|
+
...(variant === 'light' && {
|
|
1011
|
+
...(color === 'default' && {
|
|
1012
|
+
color: (theme.vars || theme).palette.primary[700],
|
|
1013
|
+
backgroundColor: (0, _styles.alpha)(theme.palette.primary[100], 0.3),
|
|
1014
|
+
...theme.applyDarkStyles({
|
|
1015
|
+
color: (theme.vars || theme).palette.primary[200],
|
|
1016
|
+
backgroundColor: (0, _styles.alpha)(theme.palette.primaryDark[700], 0.5)
|
|
1017
|
+
})
|
|
1018
|
+
}),
|
|
1019
|
+
...(color === 'warning' && {
|
|
1020
|
+
color: (theme.vars || theme).palette.warning[900],
|
|
1021
|
+
backgroundColor: (theme.vars || theme).palette.warning[100],
|
|
1022
|
+
...theme.applyDarkStyles({
|
|
1023
|
+
color: '#fff',
|
|
1024
|
+
backgroundColor: (theme.vars || theme).palette.warning[900]
|
|
1025
|
+
})
|
|
1026
|
+
}),
|
|
1027
|
+
...(color === 'success' && {
|
|
1028
|
+
color: (theme.vars || theme).palette.success[900],
|
|
1029
|
+
backgroundColor: (theme.vars || theme).palette.success[100],
|
|
1030
|
+
...theme.applyDarkStyles({
|
|
1031
|
+
color: '#fff',
|
|
1032
|
+
backgroundColor: (theme.vars || theme).palette.success[900]
|
|
1033
|
+
})
|
|
1034
|
+
})
|
|
1035
|
+
})
|
|
1036
|
+
})
|
|
877
1037
|
}
|
|
878
1038
|
},
|
|
879
1039
|
MuiList: {
|
|
@@ -943,7 +1103,7 @@ function getThemedComponents() {
|
|
|
943
1103
|
root: ({
|
|
944
1104
|
theme,
|
|
945
1105
|
ownerState
|
|
946
|
-
}) => [
|
|
1106
|
+
}) => [{
|
|
947
1107
|
backgroundImage: 'none',
|
|
948
1108
|
backgroundColor: '#fff',
|
|
949
1109
|
'&[href]': {
|
|
@@ -951,47 +1111,49 @@ function getThemedComponents() {
|
|
|
951
1111
|
},
|
|
952
1112
|
transition: theme.transitions.create(['border', 'box-shadow'], {
|
|
953
1113
|
duration: theme.transitions.duration.shortest
|
|
954
|
-
})
|
|
955
|
-
|
|
956
|
-
|
|
957
|
-
|
|
958
|
-
|
|
959
|
-
|
|
960
|
-
|
|
961
|
-
|
|
962
|
-
|
|
963
|
-
|
|
1114
|
+
}),
|
|
1115
|
+
...(ownerState.variant === 'outlined' && {
|
|
1116
|
+
display: 'block',
|
|
1117
|
+
borderColor: (theme.vars || theme).palette.grey[100],
|
|
1118
|
+
'&[href]': {
|
|
1119
|
+
textDecorationLine: 'none',
|
|
1120
|
+
boxShadow: `hsl(200, 0%, 100%) 0 2px 0 inset, ${(0, _styles.alpha)(theme.palette.grey[100], 0.3)} 0 -2px 0 inset, ${(0, _styles.alpha)(theme.palette.grey[200], 0.5)} 0 1px 2px 0`,
|
|
1121
|
+
'&:hover': {
|
|
1122
|
+
borderColor: (theme.vars || theme).palette.primary[200],
|
|
1123
|
+
boxShadow: `0px 2px 8px ${(theme.vars || theme).palette.primary[100]}`
|
|
1124
|
+
},
|
|
1125
|
+
'&:focus-visible': {
|
|
1126
|
+
outline: `3px solid ${(0, _styles.alpha)(theme.palette.primary[500], 0.5)}`,
|
|
1127
|
+
outlineOffset: '2px'
|
|
1128
|
+
}
|
|
964
1129
|
},
|
|
965
|
-
'
|
|
966
|
-
|
|
967
|
-
|
|
968
|
-
|
|
969
|
-
|
|
970
|
-
':is(a&), :is(button&)': {
|
|
971
|
-
'&:hover': {
|
|
972
|
-
borderColor: (theme.vars || theme).palette.primary[200],
|
|
973
|
-
boxShadow: `0px 4px 16px ${(theme.vars || theme).palette.grey[200]}`
|
|
974
|
-
}
|
|
975
|
-
}
|
|
976
|
-
}), theme.applyDarkStyles((0, _extends2.default)({
|
|
977
|
-
backgroundColor: (theme.vars || theme).palette.primaryDark[900]
|
|
978
|
-
}, ownerState.variant === 'outlined' && {
|
|
979
|
-
borderColor: (theme.vars || theme).palette.primaryDark[700],
|
|
980
|
-
backgroundColor: (0, _styles.alpha)(theme.palette.primaryDark[800], 0.6),
|
|
981
|
-
'&[href]': {
|
|
982
|
-
textDecorationLine: 'none',
|
|
983
|
-
boxShadow: `${(0, _styles.alpha)(theme.palette.primaryDark[700], 0.4)} 0 2px 0 inset, ${(theme.vars || theme).palette.common.black} 0 -2px 0 inset, ${(theme.vars || theme).palette.common.black} 0 1px 2px 0`,
|
|
984
|
-
'&:hover': {
|
|
985
|
-
borderColor: (0, _styles.alpha)(theme.palette.primary[600], 0.5),
|
|
986
|
-
boxShadow: `0px 2px 8px ${(0, _styles.alpha)(theme.palette.primary[900], 0.6)}`
|
|
1130
|
+
':is(a&), :is(button&)': {
|
|
1131
|
+
'&:hover': {
|
|
1132
|
+
borderColor: (theme.vars || theme).palette.primary[200],
|
|
1133
|
+
boxShadow: `0px 4px 16px ${(theme.vars || theme).palette.grey[200]}`
|
|
1134
|
+
}
|
|
987
1135
|
}
|
|
988
|
-
}
|
|
989
|
-
|
|
990
|
-
|
|
991
|
-
|
|
1136
|
+
})
|
|
1137
|
+
}, theme.applyDarkStyles({
|
|
1138
|
+
backgroundColor: (theme.vars || theme).palette.primaryDark[900],
|
|
1139
|
+
...(ownerState.variant === 'outlined' && {
|
|
1140
|
+
borderColor: (theme.vars || theme).palette.primaryDark[700],
|
|
1141
|
+
backgroundColor: (0, _styles.alpha)(theme.palette.primaryDark[800], 0.6),
|
|
1142
|
+
'&[href]': {
|
|
1143
|
+
textDecorationLine: 'none',
|
|
1144
|
+
boxShadow: `${(0, _styles.alpha)(theme.palette.primaryDark[700], 0.4)} 0 2px 0 inset, ${(theme.vars || theme).palette.common.black} 0 -2px 0 inset, ${(theme.vars || theme).palette.common.black} 0 1px 2px 0`,
|
|
1145
|
+
'&:hover': {
|
|
1146
|
+
borderColor: (0, _styles.alpha)(theme.palette.primary[600], 0.5),
|
|
1147
|
+
boxShadow: `0px 2px 8px ${(0, _styles.alpha)(theme.palette.primary[900], 0.6)}`
|
|
1148
|
+
}
|
|
1149
|
+
},
|
|
1150
|
+
':is(a&), :is(button&)': {
|
|
1151
|
+
'&:hover': {
|
|
1152
|
+
boxShadow: `0px 4px 24px ${(theme.vars || theme).palette.common.black}`
|
|
1153
|
+
}
|
|
992
1154
|
}
|
|
993
|
-
}
|
|
994
|
-
})
|
|
1155
|
+
})
|
|
1156
|
+
})]
|
|
995
1157
|
}
|
|
996
1158
|
},
|
|
997
1159
|
MuiTableCell: {
|
|
@@ -999,14 +1161,16 @@ function getThemedComponents() {
|
|
|
999
1161
|
root: ({
|
|
1000
1162
|
theme,
|
|
1001
1163
|
ownerState
|
|
1002
|
-
}) => (
|
|
1164
|
+
}) => ({
|
|
1003
1165
|
padding: theme.spacing(1, 2),
|
|
1004
|
-
borderColor: (theme.vars || theme).palette.divider
|
|
1005
|
-
|
|
1006
|
-
|
|
1007
|
-
|
|
1008
|
-
|
|
1009
|
-
|
|
1166
|
+
borderColor: (theme.vars || theme).palette.divider,
|
|
1167
|
+
...(ownerState.variant === 'head' && {
|
|
1168
|
+
color: (theme.vars || theme).palette.text.primary,
|
|
1169
|
+
fontWeight: 700
|
|
1170
|
+
}),
|
|
1171
|
+
...(ownerState.variant === 'body' && {
|
|
1172
|
+
color: (theme.vars || theme).palette.text.secondary
|
|
1173
|
+
})
|
|
1010
1174
|
})
|
|
1011
1175
|
}
|
|
1012
1176
|
},
|
|
@@ -1014,11 +1178,12 @@ function getThemedComponents() {
|
|
|
1014
1178
|
styleOverrides: {
|
|
1015
1179
|
root: ({
|
|
1016
1180
|
theme
|
|
1017
|
-
}) => (
|
|
1018
|
-
backgroundColor: '#fff'
|
|
1019
|
-
|
|
1020
|
-
|
|
1021
|
-
|
|
1181
|
+
}) => ({
|
|
1182
|
+
backgroundColor: '#fff',
|
|
1183
|
+
...theme.applyDarkStyles({
|
|
1184
|
+
backgroundColor: (theme.vars || theme).palette.primaryDark[900]
|
|
1185
|
+
})
|
|
1186
|
+
})
|
|
1022
1187
|
}
|
|
1023
1188
|
},
|
|
1024
1189
|
MuiToggleButton: {
|
|
@@ -1026,30 +1191,30 @@ function getThemedComponents() {
|
|
|
1026
1191
|
root: ({
|
|
1027
1192
|
theme,
|
|
1028
1193
|
ownerState
|
|
1029
|
-
}) => [
|
|
1194
|
+
}) => [{
|
|
1030
1195
|
textTransform: 'none',
|
|
1031
1196
|
fontWeight: theme.typography.fontWeightMedium,
|
|
1032
1197
|
color: theme.palette.text.secondary,
|
|
1033
|
-
borderColor: theme.palette.grey[200]
|
|
1034
|
-
|
|
1035
|
-
|
|
1036
|
-
|
|
1198
|
+
borderColor: theme.palette.grey[200],
|
|
1199
|
+
...(ownerState.size === 'small' && {
|
|
1200
|
+
padding: '0.375rem 0.75rem'
|
|
1201
|
+
}),
|
|
1037
1202
|
'&.Mui-selected': {
|
|
1038
1203
|
color: (theme.vars || theme).palette.primary[700],
|
|
1039
|
-
borderColor: `${(theme.vars || theme).palette.primary[
|
|
1204
|
+
borderColor: `${(theme.vars || theme).palette.primary[200]} !important`,
|
|
1040
1205
|
backgroundColor: (theme.vars || theme).palette.primary[50],
|
|
1041
1206
|
'&:hover': {
|
|
1042
1207
|
backgroundColor: (theme.vars || theme).palette.primary[100]
|
|
1043
1208
|
}
|
|
1044
1209
|
}
|
|
1045
|
-
}
|
|
1210
|
+
}, theme.applyDarkStyles({
|
|
1046
1211
|
borderColor: theme.palette.primaryDark[700],
|
|
1047
1212
|
'&:hover': {
|
|
1048
1213
|
backgroundColor: (0, _styles.alpha)(theme.palette.primaryDark[600], 0.2)
|
|
1049
1214
|
},
|
|
1050
1215
|
'&.Mui-selected': {
|
|
1051
1216
|
color: (theme.vars || theme).palette.primary[200],
|
|
1052
|
-
borderColor: `${(theme.vars || theme).palette.primary[
|
|
1217
|
+
borderColor: `${(theme.vars || theme).palette.primary[800]} !important`,
|
|
1053
1218
|
backgroundColor: (0, _styles.alpha)(theme.palette.primary[900], 0.4),
|
|
1054
1219
|
'&:hover': {
|
|
1055
1220
|
backgroundColor: (0, _styles.alpha)(theme.palette.primary[900], 0.8),
|
|
@@ -1060,11 +1225,20 @@ function getThemedComponents() {
|
|
|
1060
1225
|
}
|
|
1061
1226
|
},
|
|
1062
1227
|
MuiTooltip: {
|
|
1228
|
+
defaultProps: {
|
|
1229
|
+
arrow: true
|
|
1230
|
+
},
|
|
1063
1231
|
styleOverrides: {
|
|
1064
|
-
tooltip: {
|
|
1232
|
+
tooltip: ({
|
|
1233
|
+
theme
|
|
1234
|
+
}) => ({
|
|
1235
|
+
padding: '6px 8px',
|
|
1065
1236
|
borderRadius: 6,
|
|
1066
|
-
|
|
1067
|
-
|
|
1237
|
+
backgroundColor: (theme.vars || theme).palette.grey[800],
|
|
1238
|
+
'& .MuiTooltip-arrow': {
|
|
1239
|
+
color: (theme.vars || theme).palette.grey[800]
|
|
1240
|
+
}
|
|
1241
|
+
})
|
|
1068
1242
|
}
|
|
1069
1243
|
},
|
|
1070
1244
|
MuiSwitch: {
|
|
@@ -1091,13 +1265,14 @@ function getThemedComponents() {
|
|
|
1091
1265
|
},
|
|
1092
1266
|
track: ({
|
|
1093
1267
|
theme
|
|
1094
|
-
}) => (
|
|
1268
|
+
}) => ({
|
|
1095
1269
|
opacity: 1,
|
|
1096
1270
|
borderRadius: 32,
|
|
1097
|
-
backgroundColor: theme.palette.grey[400]
|
|
1098
|
-
|
|
1099
|
-
|
|
1100
|
-
|
|
1271
|
+
backgroundColor: theme.palette.grey[400],
|
|
1272
|
+
...theme.applyDarkStyles({
|
|
1273
|
+
backgroundColor: theme.palette.grey[800]
|
|
1274
|
+
})
|
|
1275
|
+
}),
|
|
1101
1276
|
thumb: {
|
|
1102
1277
|
flexShrink: 0,
|
|
1103
1278
|
width: '14px',
|
|
@@ -1105,6 +1280,25 @@ function getThemedComponents() {
|
|
|
1105
1280
|
}
|
|
1106
1281
|
}
|
|
1107
1282
|
},
|
|
1283
|
+
MuiSnackbar: {
|
|
1284
|
+
styleOverrides: {
|
|
1285
|
+
root: ({
|
|
1286
|
+
theme
|
|
1287
|
+
}) => ({
|
|
1288
|
+
'& .MuiSnackbarContent-root': {
|
|
1289
|
+
backgroundColor: '#FFF',
|
|
1290
|
+
color: (theme.vars || theme).palette.text.primary,
|
|
1291
|
+
fontWeight: theme.typography.fontWeightMedium,
|
|
1292
|
+
border: `1px solid ${(theme.vars || theme).palette.divider}`,
|
|
1293
|
+
boxShadow: `0 4px 16px ${(0, _styles.alpha)(theme.palette.grey[400], 0.2)}`,
|
|
1294
|
+
...theme.applyDarkStyles({
|
|
1295
|
+
backgroundColor: (theme.vars || theme).palette.primaryDark[800],
|
|
1296
|
+
boxShadow: '0 4px 16px hsl(0, 100%, 1%)'
|
|
1297
|
+
})
|
|
1298
|
+
}
|
|
1299
|
+
})
|
|
1300
|
+
}
|
|
1301
|
+
},
|
|
1108
1302
|
MuiPaginationItem: {
|
|
1109
1303
|
styleOverrides: {
|
|
1110
1304
|
root: ({
|
|
@@ -1153,5 +1347,11 @@ function getThemedComponents() {
|
|
|
1153
1347
|
}
|
|
1154
1348
|
};
|
|
1155
1349
|
}
|
|
1156
|
-
const brandingDarkTheme = exports.brandingDarkTheme = (0, _styles.createTheme)(
|
|
1157
|
-
|
|
1350
|
+
const brandingDarkTheme = exports.brandingDarkTheme = (0, _styles.createTheme)({
|
|
1351
|
+
...getDesignTokens('dark'),
|
|
1352
|
+
...getThemedComponents()
|
|
1353
|
+
});
|
|
1354
|
+
const brandingLightTheme = exports.brandingLightTheme = (0, _styles.createTheme)({
|
|
1355
|
+
...getDesignTokens('light'),
|
|
1356
|
+
...getThemedComponents()
|
|
1357
|
+
});
|