@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
|
@@ -0,0 +1,837 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
+
Object.defineProperty(exports, "__esModule", {
|
|
5
|
+
value: true
|
|
6
|
+
});
|
|
7
|
+
exports.MarkdownElement = void 0;
|
|
8
|
+
var React = _interopRequireWildcard(require("react"));
|
|
9
|
+
var _clsx = _interopRequireDefault(require("clsx"));
|
|
10
|
+
var _styles = require("@mui/material/styles");
|
|
11
|
+
var _branding = require("../branding");
|
|
12
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
|
13
|
+
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
|
|
14
|
+
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
15
|
+
const Root = (0, _styles.styled)('div')(({
|
|
16
|
+
theme
|
|
17
|
+
}) => {
|
|
18
|
+
var _theme$shape$borderRa, _theme$shape, _theme$shape$borderRa2, _theme$shape2, _theme$shape$borderRa3, _theme$shape3;
|
|
19
|
+
return {
|
|
20
|
+
..._branding.brandingLightTheme.typography.body1,
|
|
21
|
+
lineHeight: 1.6,
|
|
22
|
+
// Increased compared to the 1.5 default to make the docs easier to read.
|
|
23
|
+
color: `var(--muidocs-palette-text-primary, ${_branding.brandingLightTheme.palette.text.primary})`,
|
|
24
|
+
'& :focus-visible': {
|
|
25
|
+
outline: `3px solid ${(0, _styles.alpha)(_branding.brandingLightTheme.palette.primary[500], 0.5)}`,
|
|
26
|
+
outlineOffset: 2
|
|
27
|
+
},
|
|
28
|
+
'& strong': {
|
|
29
|
+
color: `var(--muidocs-palette-text-primary, ${_branding.brandingLightTheme.palette.text.primary})`
|
|
30
|
+
},
|
|
31
|
+
wordBreak: 'break-word',
|
|
32
|
+
'& pre': {
|
|
33
|
+
lineHeight: 1.5,
|
|
34
|
+
// Developers like when the code is dense.
|
|
35
|
+
margin: theme.spacing(2, 'auto'),
|
|
36
|
+
padding: theme.spacing(2),
|
|
37
|
+
backgroundColor: 'hsl(210, 35%, 9%)',
|
|
38
|
+
// a special, one-off, color tailored for the code blocks using MUI's branding theme blue palette as the starting point. It has a less saturaded color but still maintaining a bit of the blue tint.
|
|
39
|
+
color: 'hsl(60, 30%, 96%)',
|
|
40
|
+
colorScheme: 'dark',
|
|
41
|
+
borderRadius: `var(--muidocs-shape-borderRadius, ${(_theme$shape$borderRa = (_theme$shape = theme.shape) == null ? void 0 : _theme$shape.borderRadius) != null ? _theme$shape$borderRa : _branding.brandingLightTheme.shape.borderRadius}px)`,
|
|
42
|
+
border: '1px solid',
|
|
43
|
+
borderColor: `var(--muidocs-palette-primaryDark-700, ${_branding.brandingLightTheme.palette.primaryDark[700]})`,
|
|
44
|
+
overflow: 'auto',
|
|
45
|
+
WebkitOverflowScrolling: 'touch',
|
|
46
|
+
fontSize: _branding.brandingLightTheme.typography.pxToRem(13),
|
|
47
|
+
maxWidth: 'calc(100vw - 32px)',
|
|
48
|
+
maxHeight: '400px',
|
|
49
|
+
[_branding.brandingLightTheme.breakpoints.up('md')]: {
|
|
50
|
+
maxWidth: 'calc(100vw - 32px - 16px)'
|
|
51
|
+
}
|
|
52
|
+
},
|
|
53
|
+
'& code': {
|
|
54
|
+
..._branding.brandingLightTheme.typography.body2,
|
|
55
|
+
fontFamily: _branding.brandingLightTheme.typography.fontFamilyCode,
|
|
56
|
+
fontWeight: 400,
|
|
57
|
+
WebkitFontSmoothing: 'subpixel-antialiased'
|
|
58
|
+
},
|
|
59
|
+
'& pre > code': {
|
|
60
|
+
// Reset for Safari
|
|
61
|
+
// https://github.com/necolas/normalize.css/blob/master/normalize.css#L102
|
|
62
|
+
fontSize: 'inherit'
|
|
63
|
+
},
|
|
64
|
+
// inline code block
|
|
65
|
+
'& :not(pre) > code': {
|
|
66
|
+
padding: '2px 4px',
|
|
67
|
+
color: `var(--muidocs-palette-text-primary, ${_branding.brandingLightTheme.palette.text.primary})`,
|
|
68
|
+
backgroundColor: `var(--muidocs-palette-grey-50, ${_branding.brandingLightTheme.palette.grey[50]})`,
|
|
69
|
+
border: '1px solid',
|
|
70
|
+
borderColor: `var(--muidocs-palette-grey-200, ${_branding.brandingLightTheme.palette.grey[200]})`,
|
|
71
|
+
borderRadius: 6,
|
|
72
|
+
fontSize: _branding.brandingLightTheme.typography.pxToRem(13),
|
|
73
|
+
direction: 'ltr /*! @noflip */',
|
|
74
|
+
boxDecorationBreak: 'clone'
|
|
75
|
+
},
|
|
76
|
+
'& h1': {
|
|
77
|
+
..._branding.brandingLightTheme.typography.h3,
|
|
78
|
+
fontSize: _branding.brandingLightTheme.typography.pxToRem(36),
|
|
79
|
+
fontFamily: `"General Sans", ${_branding.brandingLightTheme.typography.fontFamilySystem}`,
|
|
80
|
+
margin: '10px 0',
|
|
81
|
+
color: `var(--muidocs-palette-primaryDark-900, ${_branding.brandingLightTheme.palette.primaryDark[900]})`,
|
|
82
|
+
fontWeight: 600,
|
|
83
|
+
letterSpacing: -0.2
|
|
84
|
+
},
|
|
85
|
+
'& .description': {
|
|
86
|
+
..._branding.brandingLightTheme.typography.subtitle1,
|
|
87
|
+
fontWeight: 400,
|
|
88
|
+
margin: '0 0 24px'
|
|
89
|
+
},
|
|
90
|
+
'& .component-tabs': {
|
|
91
|
+
margin: '0 0 40px'
|
|
92
|
+
},
|
|
93
|
+
'& h2': {
|
|
94
|
+
..._branding.brandingLightTheme.typography.h5,
|
|
95
|
+
fontFamily: `"General Sans", ${_branding.brandingLightTheme.typography.fontFamilySystem}`,
|
|
96
|
+
fontSize: theme.typography.pxToRem(26),
|
|
97
|
+
fontWeight: _branding.brandingLightTheme.typography.fontWeightSemiBold,
|
|
98
|
+
color: `var(--muidocs-palette-grey-900, ${_branding.brandingLightTheme.palette.grey[900]})`,
|
|
99
|
+
margin: '40px 0 4px'
|
|
100
|
+
},
|
|
101
|
+
'& h3': {
|
|
102
|
+
..._branding.brandingLightTheme.typography.h6,
|
|
103
|
+
fontFamily: `"General Sans", ${_branding.brandingLightTheme.typography.fontFamilySystem}`,
|
|
104
|
+
fontSize: theme.typography.pxToRem(20),
|
|
105
|
+
fontWeight: _branding.brandingLightTheme.typography.fontWeightSemiBold,
|
|
106
|
+
color: `var(--muidocs-palette-grey-900, ${_branding.brandingLightTheme.palette.grey[900]})`,
|
|
107
|
+
margin: '24px 0 4px'
|
|
108
|
+
},
|
|
109
|
+
'& h4': {
|
|
110
|
+
..._branding.brandingLightTheme.typography.subtitle1,
|
|
111
|
+
fontFamily: `"General Sans", ${_branding.brandingLightTheme.typography.fontFamilySystem}`,
|
|
112
|
+
fontWeight: _branding.brandingLightTheme.typography.fontWeightSemiBold,
|
|
113
|
+
color: `var(--muidocs-palette-grey-900, ${_branding.brandingLightTheme.palette.grey[900]})`,
|
|
114
|
+
margin: '20px 0 6px'
|
|
115
|
+
},
|
|
116
|
+
'& h5': {
|
|
117
|
+
..._branding.brandingLightTheme.typography.subtitle2,
|
|
118
|
+
fontFamily: `"General Sans", ${_branding.brandingLightTheme.typography.fontFamilySystem}`,
|
|
119
|
+
fontWeight: _branding.brandingLightTheme.typography.fontWeightSemiBold,
|
|
120
|
+
color: `var(--muidocs-palette-grey-900, ${_branding.brandingLightTheme.palette.grey[900]})`,
|
|
121
|
+
margin: '20px 0 8px'
|
|
122
|
+
},
|
|
123
|
+
'& p': {
|
|
124
|
+
marginTop: 0,
|
|
125
|
+
marginBottom: 16,
|
|
126
|
+
color: `var(--muidocs-palette-grey-900, ${_branding.brandingLightTheme.palette.grey[900]})`
|
|
127
|
+
},
|
|
128
|
+
'& ul, & ol': {
|
|
129
|
+
paddingLeft: 30,
|
|
130
|
+
marginTop: 0,
|
|
131
|
+
marginBottom: 16,
|
|
132
|
+
'& ul, & ol': {
|
|
133
|
+
marginBottom: 6
|
|
134
|
+
}
|
|
135
|
+
},
|
|
136
|
+
'& h1, & h2, & h3, & h4': {
|
|
137
|
+
display: 'flex',
|
|
138
|
+
alignItems: 'center',
|
|
139
|
+
gap: 6,
|
|
140
|
+
'& code': {
|
|
141
|
+
fontSize: 'inherit',
|
|
142
|
+
lineHeight: 'inherit',
|
|
143
|
+
// Remove scroll on small screens.
|
|
144
|
+
wordBreak: 'break-all'
|
|
145
|
+
},
|
|
146
|
+
'& .title-link-to-anchor': {
|
|
147
|
+
color: 'inherit',
|
|
148
|
+
textDecoration: 'none',
|
|
149
|
+
position: 'relative',
|
|
150
|
+
display: 'flex',
|
|
151
|
+
alignItems: 'center'
|
|
152
|
+
},
|
|
153
|
+
'& .anchor-icon': {
|
|
154
|
+
// To prevent the link to get the focus.
|
|
155
|
+
display: 'inline-flex',
|
|
156
|
+
alignItems: 'center',
|
|
157
|
+
visibility: 'hidden'
|
|
158
|
+
},
|
|
159
|
+
'& a:not(.title-link-to-anchor):hover': {
|
|
160
|
+
color: 'currentColor',
|
|
161
|
+
border: 'none',
|
|
162
|
+
boxShadow: '0 1px 0 0 currentColor',
|
|
163
|
+
textDecoration: 'none'
|
|
164
|
+
},
|
|
165
|
+
'& .anchor-icon, & .comment-link': {
|
|
166
|
+
padding: 0,
|
|
167
|
+
cursor: 'pointer',
|
|
168
|
+
alignItems: 'center',
|
|
169
|
+
justifyContent: 'center',
|
|
170
|
+
flexShrink: 0,
|
|
171
|
+
textAlign: 'center',
|
|
172
|
+
marginLeft: 8,
|
|
173
|
+
height: 26,
|
|
174
|
+
width: 26,
|
|
175
|
+
backgroundColor: `var(--muidocs-palette-primary-50, ${_branding.brandingLightTheme.palette.grey[50]})`,
|
|
176
|
+
color: `var(--muidocs-palette-grey-600, ${_branding.brandingLightTheme.palette.grey[600]})`,
|
|
177
|
+
border: '1px solid',
|
|
178
|
+
borderColor: `var(--muidocs-palette-divider, ${_branding.brandingLightTheme.palette.divider})`,
|
|
179
|
+
borderRadius: 8,
|
|
180
|
+
'&:hover': {
|
|
181
|
+
backgroundColor: (0, _styles.alpha)(_branding.brandingLightTheme.palette.primary[100], 0.4),
|
|
182
|
+
borderColor: `var(--muidocs-palette-primary-100, ${_branding.brandingLightTheme.palette.primary[100]})`,
|
|
183
|
+
color: `var(--muidocs-palette-primary-main, ${_branding.brandingLightTheme.palette.primary.main})`
|
|
184
|
+
},
|
|
185
|
+
'& svg': {
|
|
186
|
+
height: 14,
|
|
187
|
+
width: 14,
|
|
188
|
+
fill: 'currentColor',
|
|
189
|
+
pointerEvents: 'none',
|
|
190
|
+
verticalAlign: 'middle'
|
|
191
|
+
}
|
|
192
|
+
},
|
|
193
|
+
'&:hover .anchor-icon': {
|
|
194
|
+
visibility: 'visible'
|
|
195
|
+
},
|
|
196
|
+
'& .comment-link': {
|
|
197
|
+
display: 'none',
|
|
198
|
+
// So we can have the comment button opt-in.
|
|
199
|
+
marginLeft: 'auto',
|
|
200
|
+
transition: theme.transitions.create('opacity', {
|
|
201
|
+
duration: theme.transitions.duration.shortest
|
|
202
|
+
}),
|
|
203
|
+
'& svg': {
|
|
204
|
+
fill: 'currentColor',
|
|
205
|
+
marginRight: 1.5
|
|
206
|
+
}
|
|
207
|
+
}
|
|
208
|
+
},
|
|
209
|
+
'& h1 code, & h2 code, & h3 code': {
|
|
210
|
+
color: `var(--muidocs-palette-grey-900, ${_branding.brandingLightTheme.palette.grey[900]})`
|
|
211
|
+
},
|
|
212
|
+
'& h1 code': {
|
|
213
|
+
fontWeight: _branding.brandingLightTheme.typography.fontWeightSemiBold
|
|
214
|
+
},
|
|
215
|
+
'& h2 code': {
|
|
216
|
+
fontSize: _branding.brandingLightTheme.typography.pxToRem(24),
|
|
217
|
+
fontWeight: _branding.brandingLightTheme.typography.fontWeightSemiBold
|
|
218
|
+
},
|
|
219
|
+
'& h3 code': {
|
|
220
|
+
fontSize: _branding.brandingLightTheme.typography.pxToRem(18)
|
|
221
|
+
},
|
|
222
|
+
'& table': {
|
|
223
|
+
// Trade display table for scroll overflow
|
|
224
|
+
display: 'block',
|
|
225
|
+
wordBreak: 'normal',
|
|
226
|
+
overflowX: 'auto',
|
|
227
|
+
WebkitOverflowScrolling: 'touch',
|
|
228
|
+
borderCollapse: 'collapse',
|
|
229
|
+
marginBottom: '20px',
|
|
230
|
+
borderSpacing: 0,
|
|
231
|
+
'& .prop-name, & .prop-type, & .prop-default, & .slot-name, & .slot-defaultClass, & .slot-default': {
|
|
232
|
+
fontWeight: 400,
|
|
233
|
+
fontFamily: _branding.brandingLightTheme.typography.fontFamilyCode,
|
|
234
|
+
WebkitFontSmoothing: 'subpixel-antialiased',
|
|
235
|
+
fontSize: _branding.brandingLightTheme.typography.pxToRem(13)
|
|
236
|
+
},
|
|
237
|
+
'& .required': {
|
|
238
|
+
color: '#006500'
|
|
239
|
+
},
|
|
240
|
+
'& .optional': {
|
|
241
|
+
color: '#45529f'
|
|
242
|
+
},
|
|
243
|
+
'& .prop-type, & .slot-defaultClass': {
|
|
244
|
+
color: '#932981'
|
|
245
|
+
},
|
|
246
|
+
'& .prop-default, & .slot-default': {
|
|
247
|
+
borderBottom: `1px dotted var(--muidocs-palette-divider, ${_branding.brandingLightTheme.palette.divider})`
|
|
248
|
+
}
|
|
249
|
+
},
|
|
250
|
+
'& td': {
|
|
251
|
+
...theme.typography.body2,
|
|
252
|
+
borderBottom: `1px solid var(--muidocs-palette-divider, ${_branding.brandingLightTheme.palette.divider})`,
|
|
253
|
+
paddingRight: 20,
|
|
254
|
+
paddingTop: 16,
|
|
255
|
+
paddingBottom: 16,
|
|
256
|
+
color: `var(--muidocs-palette-text-secondary, ${_branding.brandingLightTheme.palette.text.secondary})`
|
|
257
|
+
},
|
|
258
|
+
'& td code': {
|
|
259
|
+
lineHeight: 1.6
|
|
260
|
+
},
|
|
261
|
+
'& th': {
|
|
262
|
+
fontSize: theme.typography.pxToRem(14),
|
|
263
|
+
lineHeight: theme.typography.pxToRem(24),
|
|
264
|
+
fontWeight: 500,
|
|
265
|
+
color: `var(--muidocs-palette-text-primary, ${_branding.brandingLightTheme.palette.text.primary})`,
|
|
266
|
+
whiteSpace: 'pre',
|
|
267
|
+
borderBottom: `1px solid var(--muidocs-palette-divider, ${_branding.brandingLightTheme.palette.divider})`,
|
|
268
|
+
paddingRight: 20,
|
|
269
|
+
paddingTop: 12,
|
|
270
|
+
paddingBottom: 12
|
|
271
|
+
},
|
|
272
|
+
'& blockquote': {
|
|
273
|
+
position: 'relative',
|
|
274
|
+
padding: '0 16px',
|
|
275
|
+
margin: 0,
|
|
276
|
+
borderLeft: '1.5px solid',
|
|
277
|
+
borderColor: `var(--muidocs-palette-grey-200, ${_branding.brandingLightTheme.palette.grey[200]})`,
|
|
278
|
+
'& p': {
|
|
279
|
+
fontSize: theme.typography.pxToRem(12.5),
|
|
280
|
+
fontFamily: _branding.brandingLightTheme.typography.fontFamilyCode,
|
|
281
|
+
fontWeight: _branding.brandingLightTheme.typography.fontWeightMedium,
|
|
282
|
+
lineHeight: theme.typography.pxToRem(24),
|
|
283
|
+
textIndent: 20
|
|
284
|
+
},
|
|
285
|
+
'&::before': {
|
|
286
|
+
position: 'absolute',
|
|
287
|
+
// eslint-disable-next-line material-ui/straight-quotes
|
|
288
|
+
content: '"“"',
|
|
289
|
+
color: `var(--muidocs-palette-grey-300, ${_branding.brandingLightTheme.palette.grey[300]})`,
|
|
290
|
+
fontSize: '2.5rem',
|
|
291
|
+
top: 8,
|
|
292
|
+
marginLeft: -6,
|
|
293
|
+
lineHeight: 0.5
|
|
294
|
+
}
|
|
295
|
+
},
|
|
296
|
+
'& .MuiCallout-root': {
|
|
297
|
+
display: 'flex',
|
|
298
|
+
gap: 12,
|
|
299
|
+
padding: '16px',
|
|
300
|
+
margin: '16px 0',
|
|
301
|
+
border: '1px solid',
|
|
302
|
+
color: `var(--muidocs-palette-text-secondary, ${_branding.brandingLightTheme.palette.text.secondary})`,
|
|
303
|
+
borderColor: `var(--muidocs-palette-grey-100, ${_branding.brandingLightTheme.palette.grey[100]})`,
|
|
304
|
+
borderRadius: `var(--muidocs-shape-borderRadius, ${(_theme$shape$borderRa2 = (_theme$shape2 = theme.shape) == null ? void 0 : _theme$shape2.borderRadius) != null ? _theme$shape$borderRa2 : _branding.brandingLightTheme.shape.borderRadius}px)`,
|
|
305
|
+
'& > code': {
|
|
306
|
+
height: 'fit-content',
|
|
307
|
+
backgroundColor: `var(--muidocs-palette-grey-100, ${_branding.brandingLightTheme.palette.grey[100]})`,
|
|
308
|
+
borderColor: `var(--muidocs-palette-grey-300, ${_branding.brandingLightTheme.palette.grey[300]})`
|
|
309
|
+
},
|
|
310
|
+
'& .MuiCallout-content': {
|
|
311
|
+
minWidth: 0,
|
|
312
|
+
// Allows content to shrink. Useful when callout contains code block
|
|
313
|
+
flexGrow: 1,
|
|
314
|
+
'& > p:last-child, & > ul:last-child': {
|
|
315
|
+
// Avoid margin on last child
|
|
316
|
+
marginBottom: 0
|
|
317
|
+
},
|
|
318
|
+
'& .MuiCode-root': {
|
|
319
|
+
'& > pre': {
|
|
320
|
+
margin: 0,
|
|
321
|
+
marginTop: 4
|
|
322
|
+
}
|
|
323
|
+
},
|
|
324
|
+
'& > ul': {
|
|
325
|
+
// Because of the gap left by the icon, we visually need less padding
|
|
326
|
+
paddingLeft: 22
|
|
327
|
+
}
|
|
328
|
+
},
|
|
329
|
+
'& > svg': {
|
|
330
|
+
marginTop: 2,
|
|
331
|
+
width: 20,
|
|
332
|
+
height: 20,
|
|
333
|
+
flexShrink: 0
|
|
334
|
+
},
|
|
335
|
+
'& > ul, & > p': {
|
|
336
|
+
'&:last-child': {
|
|
337
|
+
margin: 0
|
|
338
|
+
}
|
|
339
|
+
},
|
|
340
|
+
'& ul, li, p': {
|
|
341
|
+
color: 'inherit'
|
|
342
|
+
},
|
|
343
|
+
'&.MuiCallout-error': {
|
|
344
|
+
color: `var(--muidocs-palette-error-900, ${_branding.brandingLightTheme.palette.error[900]})`,
|
|
345
|
+
backgroundColor: `var(--muidocs-palette-error-50, ${_branding.brandingLightTheme.palette.error[50]})`,
|
|
346
|
+
borderColor: `var(--muidocs-palette-error-100, ${_branding.brandingLightTheme.palette.error[100]})`,
|
|
347
|
+
'& strong': {
|
|
348
|
+
color: `var(--muidocs-palette-error-800, ${_branding.brandingLightTheme.palette.error[800]})`
|
|
349
|
+
},
|
|
350
|
+
'& > svg': {
|
|
351
|
+
fill: `var(--muidocs-palette-error-500, ${_branding.brandingLightTheme.palette.error[600]})`
|
|
352
|
+
},
|
|
353
|
+
'& a': {
|
|
354
|
+
color: `var(--muidocs-palette-error-800, ${_branding.brandingLightTheme.palette.error[800]})`,
|
|
355
|
+
textDecorationColor: (0, _styles.alpha)(_branding.brandingLightTheme.palette.error.main, 0.4),
|
|
356
|
+
'&:hover': {
|
|
357
|
+
textDecorationColor: 'inherit'
|
|
358
|
+
}
|
|
359
|
+
}
|
|
360
|
+
},
|
|
361
|
+
'&.MuiCallout-info': {
|
|
362
|
+
color: `var(--muidocs-palette-grey-900, ${_branding.brandingLightTheme.palette.grey[900]})`,
|
|
363
|
+
backgroundColor: `var(--muidocs-palette-grey-50, ${_branding.brandingLightTheme.palette.grey[50]})`,
|
|
364
|
+
borderColor: `var(--muidocs-palette-grey-100, ${_branding.brandingLightTheme.palette.grey[100]})`,
|
|
365
|
+
'& strong': {
|
|
366
|
+
color: `var(--muidocs-palette-primary-800, ${_branding.brandingLightTheme.palette.primary[800]})`
|
|
367
|
+
},
|
|
368
|
+
'& > svg': {
|
|
369
|
+
fill: `var(--muidocs-palette-grey-600, ${_branding.brandingLightTheme.palette.grey[600]})`
|
|
370
|
+
}
|
|
371
|
+
},
|
|
372
|
+
'&.MuiCallout-success': {
|
|
373
|
+
color: `var(--muidocs-palette-success-900, ${_branding.brandingLightTheme.palette.success[900]})`,
|
|
374
|
+
backgroundColor: `var(--muidocs-palette-success-50, ${_branding.brandingLightTheme.palette.success[50]})`,
|
|
375
|
+
borderColor: `var(--muidocs-palette-success-100, ${_branding.brandingLightTheme.palette.success[100]})`,
|
|
376
|
+
'& strong': {
|
|
377
|
+
color: `var(--muidocs-palette-success-900, ${_branding.brandingLightTheme.palette.success[900]})`
|
|
378
|
+
},
|
|
379
|
+
'& > svg': {
|
|
380
|
+
fill: `var(--muidocs-palette-success-600, ${_branding.brandingLightTheme.palette.success[600]})`
|
|
381
|
+
},
|
|
382
|
+
'& a': {
|
|
383
|
+
color: `var(--muidocs-palette-success-900, ${_branding.brandingLightTheme.palette.success[900]})`,
|
|
384
|
+
textDecorationColor: (0, _styles.alpha)(_branding.brandingLightTheme.palette.success.main, 0.4),
|
|
385
|
+
'&:hover': {
|
|
386
|
+
textDecorationColor: 'inherit'
|
|
387
|
+
}
|
|
388
|
+
}
|
|
389
|
+
},
|
|
390
|
+
'&.MuiCallout-warning': {
|
|
391
|
+
color: `var(--muidocs-palette-grey-900, ${_branding.brandingLightTheme.palette.grey[900]})`,
|
|
392
|
+
backgroundColor: (0, _styles.alpha)(_branding.brandingLightTheme.palette.warning[50], 0.5),
|
|
393
|
+
borderColor: (0, _styles.alpha)(_branding.brandingLightTheme.palette.warning[700], 0.15),
|
|
394
|
+
'& strong': {
|
|
395
|
+
color: `var(--muidocs-palette-warning-800, ${_branding.brandingLightTheme.palette.warning[800]})`
|
|
396
|
+
},
|
|
397
|
+
'& > svg': {
|
|
398
|
+
fill: `var(--muidocs-palette-warning-600, ${_branding.brandingLightTheme.palette.warning[600]})`
|
|
399
|
+
},
|
|
400
|
+
'& a': {
|
|
401
|
+
color: `var(--muidocs-palette-warning-800, ${_branding.brandingLightTheme.palette.warning[800]})`,
|
|
402
|
+
textDecorationColor: (0, _styles.alpha)(_branding.brandingLightTheme.palette.warning.main, 0.4),
|
|
403
|
+
'&:hover': {
|
|
404
|
+
textDecorationColor: 'inherit'
|
|
405
|
+
}
|
|
406
|
+
}
|
|
407
|
+
}
|
|
408
|
+
},
|
|
409
|
+
'& a[target="_blank"]::after': {
|
|
410
|
+
content: '""',
|
|
411
|
+
maskImage: `url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' focusable='false' aria-hidden='true' viewBox='0 0 24 24' fill='currentColor'%3E%3Cpath d='M6 6v2h8.59L5 17.59 6.41 19 16 9.41V18h2V6z'%3E%3C/path%3E%3C/svg%3E")`,
|
|
412
|
+
display: 'inline-flex',
|
|
413
|
+
width: '1em',
|
|
414
|
+
height: '1em',
|
|
415
|
+
color: 'inherit',
|
|
416
|
+
backgroundColor: 'currentColor',
|
|
417
|
+
transform: 'translate(0, 2px)',
|
|
418
|
+
transition: 'transform 0.3s cubic-bezier(0.1, 0.8, 0.3, 1)',
|
|
419
|
+
// bounce effect
|
|
420
|
+
opacity: 0.8
|
|
421
|
+
},
|
|
422
|
+
'& a[target="_blank"]:hover::after': {
|
|
423
|
+
opacity: 1,
|
|
424
|
+
transform: 'translate(1px, 0)'
|
|
425
|
+
},
|
|
426
|
+
'& a.remove-link-arrow::after': {
|
|
427
|
+
// Allows to remove link arrows for images
|
|
428
|
+
display: 'none'
|
|
429
|
+
},
|
|
430
|
+
'& .Ad-root a::after': {
|
|
431
|
+
// Remove link arrow for ads
|
|
432
|
+
display: 'none'
|
|
433
|
+
},
|
|
434
|
+
'& a:not(.title-link-to-anchor), & a:not(.title-link-to-anchor) code': {
|
|
435
|
+
// Style taken from the Link component
|
|
436
|
+
color: `var(--muidocs-palette-primary-600, ${_branding.brandingLightTheme.palette.primary[600]})`,
|
|
437
|
+
fontWeight: theme.typography.fontWeightMedium,
|
|
438
|
+
textDecoration: 'underline',
|
|
439
|
+
textDecorationColor: (0, _styles.alpha)(_branding.brandingLightTheme.palette.primary.main, 0.4),
|
|
440
|
+
'&:hover': {
|
|
441
|
+
textDecorationColor: 'inherit'
|
|
442
|
+
}
|
|
443
|
+
},
|
|
444
|
+
'& a code': {
|
|
445
|
+
color: (0, _styles.darken)(_branding.brandingLightTheme.palette.primary.main, 0.04)
|
|
446
|
+
},
|
|
447
|
+
'& a:not(.title-link-to-anchor) code': {
|
|
448
|
+
color: (0, _styles.darken)(_branding.brandingLightTheme.palette.primary.main, 0.2)
|
|
449
|
+
},
|
|
450
|
+
'& img, & video': {
|
|
451
|
+
// Use !important so that inline style on <img> or <video> can't win.
|
|
452
|
+
// This avoid horizontal overflows on mobile.
|
|
453
|
+
maxWidth: '100% !important',
|
|
454
|
+
// Avoid the image to be fixed height, so it can respect the aspect ratio.
|
|
455
|
+
height: 'auto'
|
|
456
|
+
},
|
|
457
|
+
'& img': {
|
|
458
|
+
// Avoid layout jump
|
|
459
|
+
display: 'inline-block',
|
|
460
|
+
// Avoid very sharp edges
|
|
461
|
+
borderRadius: 2
|
|
462
|
+
},
|
|
463
|
+
'& hr': {
|
|
464
|
+
height: 1,
|
|
465
|
+
margin: theme.spacing(5, 0),
|
|
466
|
+
border: 0,
|
|
467
|
+
flexShrink: 0,
|
|
468
|
+
backgroundColor: `var(--muidocs-palette-divider, ${_branding.brandingLightTheme.palette.divider})`
|
|
469
|
+
},
|
|
470
|
+
'& kbd.key': {
|
|
471
|
+
padding: 6,
|
|
472
|
+
display: 'inline-block',
|
|
473
|
+
whiteSpace: 'nowrap',
|
|
474
|
+
margin: '0 1px',
|
|
475
|
+
fontFamily: _branding.brandingLightTheme.typography.fontFamilyCode,
|
|
476
|
+
fontSize: _branding.brandingLightTheme.typography.pxToRem(11),
|
|
477
|
+
color: `var(--muidocs-palette-text-primary, ${_branding.brandingLightTheme.palette.text.primary})`,
|
|
478
|
+
lineHeight: '10px',
|
|
479
|
+
verticalAlign: 'middle',
|
|
480
|
+
borderRadius: 6,
|
|
481
|
+
border: `1px solid var(--muidocs-palette-grey-300, ${_branding.brandingLightTheme.palette.grey[300]})`,
|
|
482
|
+
backgroundColor: `var(--muidocs-palette-grey-50, ${_branding.brandingLightTheme.palette.grey[50]})`,
|
|
483
|
+
boxShadow: `inset 0 -2px 0 var(--muidocs-palette-grey-200, ${_branding.brandingLightTheme.palette.grey[200]})`
|
|
484
|
+
},
|
|
485
|
+
'& details': {
|
|
486
|
+
width: '100%',
|
|
487
|
+
padding: theme.spacing(1),
|
|
488
|
+
marginBottom: theme.spacing(1.5),
|
|
489
|
+
border: '1px solid',
|
|
490
|
+
borderColor: `var(--muidocs-palette-divider, ${_branding.brandingLightTheme.palette.divider})`,
|
|
491
|
+
borderRadius: `var(--muidocs-shape-borderRadius, ${(_theme$shape$borderRa3 = (_theme$shape3 = theme.shape) == null ? void 0 : _theme$shape3.borderRadius) != null ? _theme$shape$borderRa3 : _branding.brandingLightTheme.shape.borderRadius}px)`,
|
|
492
|
+
'& pre': {
|
|
493
|
+
marginTop: theme.spacing(1)
|
|
494
|
+
}
|
|
495
|
+
},
|
|
496
|
+
'& summary': {
|
|
497
|
+
cursor: 'pointer',
|
|
498
|
+
padding: theme.spacing(1),
|
|
499
|
+
borderRadius: 6,
|
|
500
|
+
listStyleType: 'none',
|
|
501
|
+
display: 'flex',
|
|
502
|
+
alignItems: 'center',
|
|
503
|
+
justifyContent: 'space-between',
|
|
504
|
+
transition: theme.transitions.create(['background'], {
|
|
505
|
+
duration: theme.transitions.duration.shortest
|
|
506
|
+
}),
|
|
507
|
+
':after': {
|
|
508
|
+
content: '""',
|
|
509
|
+
maskImage: `url("data:image/svg+xml,%3Csvg width='16' height='16' viewBox='0 0 16 16' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M4 6L8 10L12 6' stroke='black' stroke-width='1.66667' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E%0A")`,
|
|
510
|
+
display: 'inline-flex',
|
|
511
|
+
width: '1em',
|
|
512
|
+
height: '1em',
|
|
513
|
+
color: 'inherit',
|
|
514
|
+
backgroundColor: 'currentColor'
|
|
515
|
+
},
|
|
516
|
+
'&:hover': {
|
|
517
|
+
backgroundColor: `var(--muidocs-palette-grey-100, ${_branding.brandingLightTheme.palette.grey[50]})`
|
|
518
|
+
}
|
|
519
|
+
},
|
|
520
|
+
'& details[open] > summary::after': {
|
|
521
|
+
content: '""',
|
|
522
|
+
maskImage: `url("data:image/svg+xml,%3Csvg width='16' height='16' viewBox='0 0 16 16' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M12 10L8 6L4 10' stroke='black' stroke-width='1.66667' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E%0A")`
|
|
523
|
+
},
|
|
524
|
+
'& .MuiCode-root': {
|
|
525
|
+
direction: 'ltr /*! @noflip */',
|
|
526
|
+
position: 'relative',
|
|
527
|
+
// Font size reset to fix a bug with Safari 16.0 when letterSpacing is set
|
|
528
|
+
fontSize: 10,
|
|
529
|
+
'&:has(.MuiCode-title)': {
|
|
530
|
+
margin: theme.spacing(2, 'auto'),
|
|
531
|
+
border: `1px solid var(--muidocs-palette-primaryDark-700, ${_branding.brandingLightTheme.palette.primaryDark[700]})`,
|
|
532
|
+
borderRadius: theme.shape.borderRadius,
|
|
533
|
+
overflow: 'clip',
|
|
534
|
+
'& .MuiCode-copy': {
|
|
535
|
+
top: '56px'
|
|
536
|
+
}
|
|
537
|
+
}
|
|
538
|
+
},
|
|
539
|
+
'& .MuiCode-copy-container': {
|
|
540
|
+
// This container is only used in demo and highlight code
|
|
541
|
+
position: 'sticky',
|
|
542
|
+
zIndex: 1,
|
|
543
|
+
top: 0
|
|
544
|
+
},
|
|
545
|
+
'& .MuiCode-copy': {
|
|
546
|
+
cursor: 'pointer',
|
|
547
|
+
position: 'absolute',
|
|
548
|
+
top: 12,
|
|
549
|
+
right: 12,
|
|
550
|
+
display: 'inline-flex',
|
|
551
|
+
flexDirection: 'row-reverse',
|
|
552
|
+
alignItems: 'center',
|
|
553
|
+
height: 24,
|
|
554
|
+
padding: theme.spacing(0.5),
|
|
555
|
+
paddingBottom: '5px',
|
|
556
|
+
// optical alignment
|
|
557
|
+
fontFamily: _branding.brandingLightTheme.typography.fontFamily,
|
|
558
|
+
fontWeight: _branding.brandingLightTheme.typography.fontWeightMedium,
|
|
559
|
+
fontSize: _branding.brandingLightTheme.typography.pxToRem(12),
|
|
560
|
+
borderRadius: 6,
|
|
561
|
+
border: '1px solid',
|
|
562
|
+
borderColor: (0, _styles.alpha)(_branding.brandingLightTheme.palette.primaryDark[600], 0.5),
|
|
563
|
+
backgroundColor: (0, _styles.alpha)(_branding.brandingLightTheme.palette.primaryDark[800], 0.5),
|
|
564
|
+
color: `var(--muidocs-palette-grey-300, ${_branding.brandingLightTheme.palette.grey[300]})`,
|
|
565
|
+
transition: theme.transitions.create(['background', 'borderColor', 'display'], {
|
|
566
|
+
duration: theme.transitions.duration.shortest
|
|
567
|
+
}),
|
|
568
|
+
'& .MuiCode-copied-label': {
|
|
569
|
+
display: 'none'
|
|
570
|
+
},
|
|
571
|
+
'&:hover, &:focus': {
|
|
572
|
+
borderColor: `var(--muidocs-palette-primaryDark-400, ${_branding.brandingLightTheme.palette.primaryDark[400]})`,
|
|
573
|
+
backgroundColor: `var(--muidocs-palette-primaryDark-700, ${_branding.brandingLightTheme.palette.primaryDark[700]})`,
|
|
574
|
+
color: '#FFF',
|
|
575
|
+
'& .MuiCode-copyKeypress': {
|
|
576
|
+
display: 'block',
|
|
577
|
+
// Approximate no hover capabilities with no keyboard
|
|
578
|
+
// https://github.com/w3c/csswg-drafts/issues/3871
|
|
579
|
+
'@media (any-hover: none)': {
|
|
580
|
+
display: 'none'
|
|
581
|
+
}
|
|
582
|
+
}
|
|
583
|
+
},
|
|
584
|
+
'& .MuiCode-copyKeypress': {
|
|
585
|
+
display: 'none',
|
|
586
|
+
position: 'absolute',
|
|
587
|
+
right: 34
|
|
588
|
+
},
|
|
589
|
+
'&[data-copied]': {
|
|
590
|
+
borderColor: `var(--muidocs-palette-primaryDark-400, ${_branding.brandingLightTheme.palette.primaryDark[400]})`,
|
|
591
|
+
backgroundColor: `var(--muidocs-palette-primaryDark-700, ${_branding.brandingLightTheme.palette.primaryDark[700]})`,
|
|
592
|
+
color: '#fff',
|
|
593
|
+
'& .MuiCode-copyKeypress': {
|
|
594
|
+
opacity: 0
|
|
595
|
+
},
|
|
596
|
+
'& .MuiCode-copy-label': {
|
|
597
|
+
display: 'none'
|
|
598
|
+
},
|
|
599
|
+
'& .MuiCode-copied-label': {
|
|
600
|
+
display: 'block'
|
|
601
|
+
}
|
|
602
|
+
}
|
|
603
|
+
},
|
|
604
|
+
'& .MuiCode-copyKeypress': {
|
|
605
|
+
pointerEvents: 'none',
|
|
606
|
+
userSelect: 'none',
|
|
607
|
+
marginRight: theme.spacing(1.2),
|
|
608
|
+
marginBottom: theme.spacing(0.2),
|
|
609
|
+
whiteSpace: 'nowrap',
|
|
610
|
+
opacity: 0.6
|
|
611
|
+
},
|
|
612
|
+
'& li': {
|
|
613
|
+
// tight lists https://spec.commonmark.org/0.30/#tight
|
|
614
|
+
marginBottom: 4,
|
|
615
|
+
'& pre': {
|
|
616
|
+
marginTop: theme.spacing(1)
|
|
617
|
+
},
|
|
618
|
+
// loose lists https://spec.commonmark.org/0.30/#loose
|
|
619
|
+
'& > p': {
|
|
620
|
+
marginBottom: theme.spacing(1)
|
|
621
|
+
}
|
|
622
|
+
},
|
|
623
|
+
'& .feature-list': {
|
|
624
|
+
padding: 0,
|
|
625
|
+
listStyle: 'none',
|
|
626
|
+
'& li': {
|
|
627
|
+
marginBottom: 6,
|
|
628
|
+
display: 'flex',
|
|
629
|
+
alignItems: 'center',
|
|
630
|
+
gap: 12,
|
|
631
|
+
'::before': {
|
|
632
|
+
content: `url('/static/branding/pricing/yes-light.svg')`,
|
|
633
|
+
width: '18px',
|
|
634
|
+
height: '18px'
|
|
635
|
+
}
|
|
636
|
+
}
|
|
637
|
+
},
|
|
638
|
+
'& .MuiCode-title': {
|
|
639
|
+
padding: theme.spacing(1.5),
|
|
640
|
+
display: 'flex',
|
|
641
|
+
alignItems: 'center',
|
|
642
|
+
gap: theme.spacing(1.5),
|
|
643
|
+
borderBottom: `1px solid var(--muidocs-palette-primaryDark-700, ${_branding.brandingLightTheme.palette.primaryDark[700]})`,
|
|
644
|
+
backgroundColor: `var(--muidocs-palette-primaryDark-900, ${_branding.brandingLightTheme.palette.primaryDark[900]})`,
|
|
645
|
+
fontFamily: theme.typography.fontFamilyCode,
|
|
646
|
+
fontSize: theme.typography.pxToRem(12),
|
|
647
|
+
fontWeight: theme.typography.fontWeightBold,
|
|
648
|
+
color: `var(--muidocs-palette-grey-200, ${_branding.brandingLightTheme.palette.grey[200]})`,
|
|
649
|
+
'::before': {
|
|
650
|
+
content: `url("data:image/svg+xml,%3Csvg width='16' height='16' viewBox='0 0 16 16' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M13.3333 3.99996H8L7.06 3.05996C6.80667 2.80663 6.46667 2.66663 6.11334 2.66663H2.66667C1.93334 2.66663 1.34 3.26663 1.34 3.99996L1.33334 12C1.33334 12.7333 1.93334 13.3333 2.66667 13.3333H13.3333C14.0667 13.3333 14.6667 12.7333 14.6667 12V5.33329C14.6667 4.59996 14.0667 3.99996 13.3333 3.99996ZM12.6667 12H3.33334C2.96667 12 2.66667 11.7 2.66667 11.3333V5.99996C2.66667 5.63329 2.96667 5.33329 3.33334 5.33329H12.6667C13.0333 5.33329 13.3333 5.63329 13.3333 5.99996V11.3333C13.3333 11.7 13.0333 12 12.6667 12Z' fill='%2399CCF3'/%3E%3C/svg%3E%0A");`,
|
|
651
|
+
width: '16px',
|
|
652
|
+
height: '16px'
|
|
653
|
+
},
|
|
654
|
+
'& + pre': {
|
|
655
|
+
margin: 0,
|
|
656
|
+
border: 'none',
|
|
657
|
+
borderRadius: 0
|
|
658
|
+
}
|
|
659
|
+
}
|
|
660
|
+
};
|
|
661
|
+
}, ({
|
|
662
|
+
theme
|
|
663
|
+
}) => ({
|
|
664
|
+
[`:where(${theme.vars ? '[data-mui-color-scheme="dark"]' : '.mode-dark'}) &`]: {
|
|
665
|
+
color: 'rgb(255, 255, 255)',
|
|
666
|
+
'& :not(pre) > code': {
|
|
667
|
+
// inline code block
|
|
668
|
+
color: `var(--muidocs-palette-text-primary, ${_branding.brandingDarkTheme.palette.text.primary})`,
|
|
669
|
+
borderColor: (0, _styles.alpha)(_branding.brandingDarkTheme.palette.primaryDark[600], 0.6),
|
|
670
|
+
backgroundColor: `var(--muidocs-palette-grey-900, ${_branding.brandingDarkTheme.palette.grey[900]})`
|
|
671
|
+
},
|
|
672
|
+
'& strong': {
|
|
673
|
+
color: `var(--muidocs-palette-grey-200, ${_branding.brandingDarkTheme.palette.grey[200]})`
|
|
674
|
+
},
|
|
675
|
+
'& hr': {
|
|
676
|
+
backgroundColor: `var(--muidocs-palette-divider, ${_branding.brandingDarkTheme.palette.divider})`
|
|
677
|
+
},
|
|
678
|
+
'& h1, & h2, & h3, & h4, & h5': {
|
|
679
|
+
color: `var(--muidocs-palette-grey-50, ${_branding.brandingDarkTheme.palette.grey[50]})`
|
|
680
|
+
},
|
|
681
|
+
'& p, & ul, & ol': {
|
|
682
|
+
color: `var(--muidocs-palette-grey-400, ${_branding.brandingDarkTheme.palette.grey[400]})`
|
|
683
|
+
},
|
|
684
|
+
'& h1, & h2, & h3, & h4': {
|
|
685
|
+
'&:hover .anchor-icon, & .comment-link': {
|
|
686
|
+
color: `var(--muidocs-palette-primary-300, ${_branding.brandingDarkTheme.palette.primaryDark[300]})`,
|
|
687
|
+
borderColor: `var(--muidocs-palette-divider, ${_branding.brandingDarkTheme.palette.divider})`,
|
|
688
|
+
backgroundColor: (0, _styles.alpha)(_branding.brandingDarkTheme.palette.primaryDark[700], 0.5),
|
|
689
|
+
'&:hover': {
|
|
690
|
+
borderColor: `var(--muidocs-palette-primary-900, ${_branding.brandingDarkTheme.palette.primary[900]})`,
|
|
691
|
+
backgroundColor: (0, _styles.alpha)(_branding.brandingDarkTheme.palette.primary[900], 0.6),
|
|
692
|
+
color: `var(--muidocs-palette-primary-100, ${_branding.brandingDarkTheme.palette.primary[100]})`
|
|
693
|
+
}
|
|
694
|
+
}
|
|
695
|
+
},
|
|
696
|
+
'& h1 code, & h2 code, & h3 code': {
|
|
697
|
+
color: `var(--muidocs-palette-grey-100, ${_branding.brandingDarkTheme.palette.grey[100]})`
|
|
698
|
+
},
|
|
699
|
+
'& table': {
|
|
700
|
+
'& .required': {
|
|
701
|
+
color: '#a5ffa5'
|
|
702
|
+
},
|
|
703
|
+
'& .optional': {
|
|
704
|
+
color: '#a5b3ff'
|
|
705
|
+
},
|
|
706
|
+
'& .prop-type, & .slot-defaultClass': {
|
|
707
|
+
color: '#ffb6ec'
|
|
708
|
+
},
|
|
709
|
+
'& .prop-default, & .slot-default': {
|
|
710
|
+
borderColor: `var(--muidocs-palette-divider, ${_branding.brandingDarkTheme.palette.divider})`
|
|
711
|
+
}
|
|
712
|
+
},
|
|
713
|
+
'& td': {
|
|
714
|
+
color: `var(--muidocs-palette-text-secondary, ${_branding.brandingDarkTheme.palette.text.secondary})`,
|
|
715
|
+
borderColor: `var(--muidocs-palette-divider, ${_branding.brandingDarkTheme.palette.divider})`
|
|
716
|
+
},
|
|
717
|
+
'& th': {
|
|
718
|
+
color: `var(--muidocs-palette-text-primary, ${_branding.brandingDarkTheme.palette.text.primary})`,
|
|
719
|
+
borderColor: `var(--muidocs-palette-divider, ${_branding.brandingDarkTheme.palette.divider})`
|
|
720
|
+
},
|
|
721
|
+
'& blockquote': {
|
|
722
|
+
borderColor: `var(--muidocs-palette-primaryDark-700, ${_branding.brandingDarkTheme.palette.primaryDark[700]})`,
|
|
723
|
+
'&::before': {
|
|
724
|
+
color: `var(--muidocs-palette-primaryDark-500, ${_branding.brandingDarkTheme.palette.primaryDark[500]})`
|
|
725
|
+
}
|
|
726
|
+
},
|
|
727
|
+
'& .MuiCallout-root': {
|
|
728
|
+
borderColor: `var(--muidocs-palette-primaryDark-700, ${_branding.brandingDarkTheme.palette.primaryDark[700]})`,
|
|
729
|
+
'& > code': {
|
|
730
|
+
height: 'fit-content',
|
|
731
|
+
backgroundColor: `var(--muidocs-palette-primaryDark-600, ${_branding.brandingDarkTheme.palette.primaryDark[600]})`,
|
|
732
|
+
borderColor: `var(--muidocs-palette-primaryDark-500, ${_branding.brandingDarkTheme.palette.primaryDark[500]})`
|
|
733
|
+
},
|
|
734
|
+
'&.MuiCallout-error': {
|
|
735
|
+
color: `var(--muidocs-palette-error-50, ${_branding.brandingDarkTheme.palette.error[50]})`,
|
|
736
|
+
backgroundColor: (0, _styles.alpha)(_branding.brandingDarkTheme.palette.error[700], 0.15),
|
|
737
|
+
borderColor: (0, _styles.alpha)(_branding.brandingDarkTheme.palette.error[400], 0.1),
|
|
738
|
+
'& strong': {
|
|
739
|
+
color: `var(--muidocs-palette-error-300, ${_branding.brandingDarkTheme.palette.error[300]})`
|
|
740
|
+
},
|
|
741
|
+
'& > svg': {
|
|
742
|
+
fill: `var(--muidocs-palette-error-500, ${_branding.brandingDarkTheme.palette.error[500]})`
|
|
743
|
+
},
|
|
744
|
+
'& a': {
|
|
745
|
+
color: `var(--muidocs-palette-error-200, ${_branding.brandingDarkTheme.palette.error[200]})`
|
|
746
|
+
}
|
|
747
|
+
},
|
|
748
|
+
'&.MuiCallout-info': {
|
|
749
|
+
color: `var(--muidocs-palette-grey-50, ${_branding.brandingDarkTheme.palette.grey[50]})`,
|
|
750
|
+
backgroundColor: (0, _styles.alpha)(_branding.brandingDarkTheme.palette.grey[700], 0.15),
|
|
751
|
+
borderColor: (0, _styles.alpha)(_branding.brandingDarkTheme.palette.grey[800], 0.5),
|
|
752
|
+
'& strong': {
|
|
753
|
+
color: `var(--muidocs-palette-primary-200, ${_branding.brandingDarkTheme.palette.primary[200]})`
|
|
754
|
+
},
|
|
755
|
+
'& > svg': {
|
|
756
|
+
fill: `var(--muidocs-palette-grey-400, ${_branding.brandingDarkTheme.palette.grey[400]})`
|
|
757
|
+
}
|
|
758
|
+
},
|
|
759
|
+
'&.MuiCallout-success': {
|
|
760
|
+
color: `var(--muidocs-palette-success-50, ${_branding.brandingDarkTheme.palette.success[50]})`,
|
|
761
|
+
backgroundColor: (0, _styles.alpha)(_branding.brandingDarkTheme.palette.success[700], 0.12),
|
|
762
|
+
borderColor: (0, _styles.alpha)(_branding.brandingLightTheme.palette.success[400], 0.1),
|
|
763
|
+
'& strong': {
|
|
764
|
+
color: `var(--muidocs-palette-success-200, ${_branding.brandingDarkTheme.palette.success[200]})`
|
|
765
|
+
},
|
|
766
|
+
'& > svg': {
|
|
767
|
+
fill: `var(--muidocs-palette-success-500, ${_branding.brandingDarkTheme.palette.success[500]})`
|
|
768
|
+
},
|
|
769
|
+
'& a': {
|
|
770
|
+
color: `var(--muidocs-palette-success-100, ${_branding.brandingDarkTheme.palette.success[100]})`
|
|
771
|
+
}
|
|
772
|
+
},
|
|
773
|
+
'&.MuiCallout-warning': {
|
|
774
|
+
color: `var(--muidocs-palette-warning-50, ${_branding.brandingDarkTheme.palette.warning[50]})`,
|
|
775
|
+
backgroundColor: (0, _styles.alpha)(_branding.brandingDarkTheme.palette.warning[700], 0.12),
|
|
776
|
+
borderColor: (0, _styles.alpha)(_branding.brandingDarkTheme.palette.warning[400], 0.1),
|
|
777
|
+
'& strong': {
|
|
778
|
+
color: `var(--muidocs-palette-warning-200, ${_branding.brandingDarkTheme.palette.warning[200]})`
|
|
779
|
+
},
|
|
780
|
+
'& > svg': {
|
|
781
|
+
fill: `var(--muidocs-palette-warning-400, ${_branding.brandingDarkTheme.palette.warning[400]})`
|
|
782
|
+
},
|
|
783
|
+
'& a': {
|
|
784
|
+
color: `var(--muidocs-palette-warning-100, ${_branding.brandingDarkTheme.palette.warning[100]})`
|
|
785
|
+
}
|
|
786
|
+
}
|
|
787
|
+
},
|
|
788
|
+
'& a:not(.title-link-to-anchor), & a:not(.title-link-to-anchor) code': {
|
|
789
|
+
color: `var(--muidocs-palette-primary-300, ${_branding.brandingDarkTheme.palette.primary[300]})`
|
|
790
|
+
},
|
|
791
|
+
'& a:not(.title-link-to-anchor) code': {
|
|
792
|
+
color: `var(--muidocs-palette-primary-light, ${_branding.brandingDarkTheme.palette.primary.light})`
|
|
793
|
+
},
|
|
794
|
+
'& kbd.key': {
|
|
795
|
+
color: `var(--muidocs-palette-text-primary, ${_branding.brandingDarkTheme.palette.text.primary})`,
|
|
796
|
+
backgroundColor: `var(--muidocs-palette-primaryDark-800, ${_branding.brandingDarkTheme.palette.primaryDark[800]})`,
|
|
797
|
+
border: `1px solid var(--muidocs-palette-primaryDark-600, ${_branding.brandingDarkTheme.palette.primaryDark[600]})`,
|
|
798
|
+
boxShadow: `inset 0 -2px 0 var(--muidocs-palette-primaryDark-700, ${_branding.brandingDarkTheme.palette.primaryDark[700]})`
|
|
799
|
+
},
|
|
800
|
+
'& details': {
|
|
801
|
+
borderColor: `var(--muidocs-palette-divider, ${_branding.brandingDarkTheme.palette.divider})`
|
|
802
|
+
},
|
|
803
|
+
'& summary': {
|
|
804
|
+
'&:hover': {
|
|
805
|
+
backgroundColor: `var(--muidocs-palette-primaryDark-800, ${_branding.brandingDarkTheme.palette.primaryDark[800]})`
|
|
806
|
+
}
|
|
807
|
+
},
|
|
808
|
+
'& .feature-list': {
|
|
809
|
+
'& li': {
|
|
810
|
+
'::before': {
|
|
811
|
+
content: `url('/static/branding/pricing/yes-dark.svg')`
|
|
812
|
+
}
|
|
813
|
+
}
|
|
814
|
+
}
|
|
815
|
+
}
|
|
816
|
+
}));
|
|
817
|
+
const MarkdownElement = exports.MarkdownElement = /*#__PURE__*/React.forwardRef(function MarkdownElement(props, ref) {
|
|
818
|
+
const {
|
|
819
|
+
className,
|
|
820
|
+
renderedMarkdown,
|
|
821
|
+
...other
|
|
822
|
+
} = props;
|
|
823
|
+
const more = {};
|
|
824
|
+
if (typeof renderedMarkdown === 'string') {
|
|
825
|
+
// workaround for https://github.com/facebook/react/issues/17170
|
|
826
|
+
// otherwise we could just set `dangerouslySetInnerHTML={undefined}`
|
|
827
|
+
more.dangerouslySetInnerHTML = {
|
|
828
|
+
__html: renderedMarkdown
|
|
829
|
+
};
|
|
830
|
+
}
|
|
831
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(Root, {
|
|
832
|
+
className: (0, _clsx.default)('markdown-body', className),
|
|
833
|
+
...more,
|
|
834
|
+
...other,
|
|
835
|
+
ref: ref
|
|
836
|
+
});
|
|
837
|
+
});
|