@mui/docs 9.0.0-alpha.0 → 9.0.0-alpha.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (181) hide show
  1. package/{esm/Ad/Ad.js → Ad/Ad.mjs} +5 -5
  2. package/{esm/Ad/AdCarbon.js → Ad/AdCarbon.mjs} +3 -3
  3. package/{esm/Ad/AdDisplay.js → Ad/AdDisplay.mjs} +4 -4
  4. package/{esm/Ad/AdGuest.js → Ad/AdGuest.mjs} +1 -1
  5. package/{esm/Ad/AdInHouse.d.ts → Ad/AdInHouse.d.mts} +1 -1
  6. package/{esm/Ad/AdInHouse.js → Ad/AdInHouse.mjs} +1 -1
  7. package/{esm/Ad/ad.styles.d.ts → Ad/ad.styles.d.mts} +4 -4
  8. package/Ad/ad.styles.d.ts +4 -4
  9. package/Ad/index.d.mts +5 -0
  10. package/Ad/index.mjs +7 -0
  11. package/CHANGELOG.md +74 -0
  12. package/{esm/CodeCopy/CodeCopyButton.js → CodeCopy/CodeCopyButton.mjs} +1 -1
  13. package/CodeCopy/index.d.mts +3 -0
  14. package/CodeCopy/index.mjs +3 -0
  15. package/{esm/ComponentLinkHeader/ComponentLinkHeader.js → ComponentLinkHeader/ComponentLinkHeader.mjs} +7 -7
  16. package/{esm/ComponentLinkHeader/index.d.ts → ComponentLinkHeader/index.d.mts} +2 -2
  17. package/{esm/ComponentLinkHeader/index.js → ComponentLinkHeader/index.mjs} +2 -2
  18. package/{esm/DocsProvider/DocsProvider.d.ts → DocsProvider/DocsProvider.d.mts} +2 -2
  19. package/{esm/DocsProvider/DocsProvider.js → DocsProvider/DocsProvider.mjs} +2 -2
  20. package/DocsProvider/index.d.mts +1 -0
  21. package/DocsProvider/index.mjs +1 -0
  22. package/{esm/HighlightedCode/HighlightedCode.js → HighlightedCode/HighlightedCode.mjs} +2 -2
  23. package/HighlightedCode/index.d.mts +1 -0
  24. package/HighlightedCode/index.mjs +1 -0
  25. package/{esm/HighlightedCodeWithTabs/HighlightedCodeWithTabs.js → HighlightedCodeWithTabs/HighlightedCodeWithTabs.mjs} +1 -1
  26. package/HighlightedCodeWithTabs/index.d.mts +2 -0
  27. package/HighlightedCodeWithTabs/index.mjs +2 -0
  28. package/IconImage/IconImage.d.mts +11 -0
  29. package/IconImage/IconImage.d.ts +11 -0
  30. package/IconImage/IconImage.js +91 -0
  31. package/IconImage/IconImage.mjs +83 -0
  32. package/IconImage/index.d.mts +1 -0
  33. package/IconImage/index.d.ts +1 -0
  34. package/IconImage/index.js +13 -0
  35. package/IconImage/index.mjs +1 -0
  36. package/{esm/InfoCard/InfoCard.d.ts → InfoCard/InfoCard.d.mts} +1 -1
  37. package/{esm/InfoCard/InfoCard.js → InfoCard/InfoCard.mjs} +1 -1
  38. package/InfoCard/index.d.mts +1 -0
  39. package/InfoCard/index.mjs +1 -0
  40. package/{esm/Link/Link.js → Link/Link.mjs} +2 -2
  41. package/Link/index.d.mts +1 -0
  42. package/Link/index.mjs +1 -0
  43. package/{esm/MarkdownElement/MarkdownElement.js → MarkdownElement/MarkdownElement.mjs} +1 -1
  44. package/MarkdownElement/index.d.mts +1 -0
  45. package/MarkdownElement/index.mjs +1 -0
  46. package/NProgressBar/index.d.mts +2 -0
  47. package/NProgressBar/index.mjs +1 -0
  48. package/SectionHeadline/SectionHeadline.d.mts +13 -0
  49. package/SectionHeadline/SectionHeadline.d.ts +13 -0
  50. package/SectionHeadline/SectionHeadline.js +89 -0
  51. package/SectionHeadline/SectionHeadline.mjs +81 -0
  52. package/SectionHeadline/index.d.mts +2 -0
  53. package/SectionHeadline/index.d.ts +2 -0
  54. package/SectionHeadline/index.js +25 -0
  55. package/SectionHeadline/index.mjs +2 -0
  56. package/SectionTitle/index.d.mts +1 -0
  57. package/SectionTitle/index.mjs +1 -0
  58. package/ThemeContext/ThemeContext.d.mts +92 -0
  59. package/ThemeContext/ThemeContext.d.ts +92 -0
  60. package/ThemeContext/ThemeContext.js +212 -0
  61. package/ThemeContext/ThemeContext.mjs +200 -0
  62. package/ThemeContext/index.d.mts +1 -0
  63. package/ThemeContext/index.d.ts +1 -0
  64. package/ThemeContext/index.js +42 -0
  65. package/ThemeContext/index.mjs +1 -0
  66. package/{esm/branding/BrandingProvider.js → branding/BrandingProvider.mjs} +1 -1
  67. package/branding/index.d.mts +2 -0
  68. package/branding/index.mjs +2 -0
  69. package/i18n/i18n.js +3 -1
  70. package/{esm/i18n/i18n.js → i18n/i18n.mjs} +4 -2
  71. package/i18n/index.d.mts +1 -0
  72. package/i18n/index.mjs +1 -0
  73. package/package.json +265 -8
  74. package/translations/index.d.mts +3 -0
  75. package/useLazyCSS/index.d.mts +1 -0
  76. package/useLazyCSS/index.d.ts +1 -0
  77. package/useLazyCSS/index.js +13 -0
  78. package/useLazyCSS/index.mjs +1 -0
  79. package/useLazyCSS/useLazyCSS.d.mts +11 -0
  80. package/useLazyCSS/useLazyCSS.d.ts +11 -0
  81. package/useLazyCSS/useLazyCSS.js +76 -0
  82. package/useLazyCSS/useLazyCSS.mjs +70 -0
  83. package/esm/Ad/index.d.ts +0 -5
  84. package/esm/Ad/index.js +0 -7
  85. package/esm/CodeCopy/index.d.ts +0 -3
  86. package/esm/CodeCopy/index.js +0 -3
  87. package/esm/DocsProvider/index.d.ts +0 -1
  88. package/esm/DocsProvider/index.js +0 -1
  89. package/esm/HighlightedCode/index.d.ts +0 -1
  90. package/esm/HighlightedCode/index.js +0 -1
  91. package/esm/HighlightedCodeWithTabs/index.d.ts +0 -2
  92. package/esm/HighlightedCodeWithTabs/index.js +0 -2
  93. package/esm/InfoCard/index.d.ts +0 -1
  94. package/esm/InfoCard/index.js +0 -1
  95. package/esm/Link/index.d.ts +0 -1
  96. package/esm/Link/index.js +0 -1
  97. package/esm/MarkdownElement/index.d.ts +0 -1
  98. package/esm/MarkdownElement/index.js +0 -1
  99. package/esm/NProgressBar/index.d.ts +0 -2
  100. package/esm/NProgressBar/index.js +0 -1
  101. package/esm/SectionTitle/index.d.ts +0 -1
  102. package/esm/SectionTitle/index.js +0 -1
  103. package/esm/branding/index.d.ts +0 -2
  104. package/esm/branding/index.js +0 -2
  105. package/esm/i18n/index.d.ts +0 -1
  106. package/esm/i18n/index.js +0 -1
  107. package/esm/nextFonts/fonts/GeneralSans-Bold.ttf +0 -0
  108. package/esm/nextFonts/fonts/GeneralSans-Bold.woff2 +0 -0
  109. package/esm/nextFonts/fonts/GeneralSans-Medium.ttf +0 -0
  110. package/esm/nextFonts/fonts/GeneralSans-Medium.woff2 +0 -0
  111. package/esm/nextFonts/fonts/GeneralSans-Regular.ttf +0 -0
  112. package/esm/nextFonts/fonts/GeneralSans-Regular.woff2 +0 -0
  113. package/esm/nextFonts/fonts/GeneralSans-Semibold-subset.woff2 +0 -0
  114. package/esm/nextFonts/fonts/GeneralSans-Semibold.ttf +0 -0
  115. package/esm/nextFonts/fonts/GeneralSans-Semibold.woff2 +0 -0
  116. package/esm/nextFonts/fonts/IBMPlexSans-Bold.ttf +0 -0
  117. package/esm/nextFonts/fonts/IBMPlexSans-Bold.woff +0 -0
  118. package/esm/nextFonts/fonts/IBMPlexSans-Bold.woff2 +0 -0
  119. package/esm/nextFonts/fonts/IBMPlexSans-Medium.ttf +0 -0
  120. package/esm/nextFonts/fonts/IBMPlexSans-Medium.woff +0 -0
  121. package/esm/nextFonts/fonts/IBMPlexSans-Medium.woff2 +0 -0
  122. package/esm/nextFonts/fonts/IBMPlexSans-Regular-subset.woff2 +0 -0
  123. package/esm/nextFonts/fonts/IBMPlexSans-Regular.ttf +0 -0
  124. package/esm/nextFonts/fonts/IBMPlexSans-Regular.woff +0 -0
  125. package/esm/nextFonts/fonts/IBMPlexSans-Regular.woff2 +0 -0
  126. package/esm/nextFonts/fonts/IBMPlexSans-SemiBold.ttf +0 -0
  127. package/esm/nextFonts/fonts/IBMPlexSans-SemiBold.woff +0 -0
  128. package/esm/nextFonts/fonts/IBMPlexSans-SemiBold.woff2 +0 -0
  129. package/esm/package.json +0 -1
  130. package/esm/translations/index.d.ts +0 -3
  131. package/esm/translations/translations.json +0 -223
  132. /package/{esm/Ad/Ad.d.ts → Ad/Ad.d.mts} +0 -0
  133. /package/{esm/Ad/AdCarbon.d.ts → Ad/AdCarbon.d.mts} +0 -0
  134. /package/{esm/Ad/AdDisplay.d.ts → Ad/AdDisplay.d.mts} +0 -0
  135. /package/{esm/Ad/AdGuest.d.ts → Ad/AdGuest.d.mts} +0 -0
  136. /package/{esm/Ad/AdManager.d.ts → Ad/AdManager.d.mts} +0 -0
  137. /package/{esm/Ad/AdManager.js → Ad/AdManager.mjs} +0 -0
  138. /package/{esm/Ad/AdProvider.d.ts → Ad/AdProvider.d.mts} +0 -0
  139. /package/{esm/Ad/AdProvider.js → Ad/AdProvider.mjs} +0 -0
  140. /package/{esm/Ad/ad.styles.js → Ad/ad.styles.mjs} +0 -0
  141. /package/{esm/CodeCopy/CodeCopy.d.ts → CodeCopy/CodeCopy.d.mts} +0 -0
  142. /package/{esm/CodeCopy/CodeCopy.js → CodeCopy/CodeCopy.mjs} +0 -0
  143. /package/{esm/CodeCopy/CodeCopyButton.d.ts → CodeCopy/CodeCopyButton.d.mts} +0 -0
  144. /package/{esm/CodeCopy/useClipboardCopy.d.ts → CodeCopy/useClipboardCopy.d.mts} +0 -0
  145. /package/{esm/CodeCopy/useClipboardCopy.js → CodeCopy/useClipboardCopy.mjs} +0 -0
  146. /package/{esm/ComponentLinkHeader/ComponentLinkHeader.d.ts → ComponentLinkHeader/ComponentLinkHeader.d.mts} +0 -0
  147. /package/{esm/HighlightedCode/HighlightedCode.d.ts → HighlightedCode/HighlightedCode.d.mts} +0 -0
  148. /package/{esm/HighlightedCodeWithTabs/HighlightedCodeWithTabs.d.ts → HighlightedCodeWithTabs/HighlightedCodeWithTabs.d.mts} +0 -0
  149. /package/{esm/Link/Link.d.ts → Link/Link.d.mts} +0 -0
  150. /package/{esm/MarkdownElement/MarkdownElement.d.ts → MarkdownElement/MarkdownElement.d.mts} +0 -0
  151. /package/{esm/NProgressBar/NProgressBar.d.ts → NProgressBar/NProgressBar.d.mts} +0 -0
  152. /package/{esm/NProgressBar/NProgressBar.js → NProgressBar/NProgressBar.mjs} +0 -0
  153. /package/{esm/SectionTitle/SectionTitle.d.ts → SectionTitle/SectionTitle.d.mts} +0 -0
  154. /package/{esm/SectionTitle/SectionTitle.js → SectionTitle/SectionTitle.mjs} +0 -0
  155. /package/{esm/branding/BrandingProvider.d.ts → branding/BrandingProvider.d.mts} +0 -0
  156. /package/{esm/branding/brandingTheme.d.ts → branding/brandingTheme.d.mts} +0 -0
  157. /package/{esm/branding/brandingTheme.js → branding/brandingTheme.mjs} +0 -0
  158. /package/{esm/i18n/i18n.d.ts → i18n/i18n.d.mts} +0 -0
  159. /package/{esm/nextFonts/index.d.ts → nextFonts/index.d.mts} +0 -0
  160. /package/{esm/nextFonts/index.js → nextFonts/index.mjs} +0 -0
  161. /package/{esm/svgIcons/BundleSizeIcon.d.ts → svgIcons/BundleSizeIcon.d.mts} +0 -0
  162. /package/{esm/svgIcons/BundleSizeIcon.js → svgIcons/BundleSizeIcon.mjs} +0 -0
  163. /package/{esm/svgIcons/FigmaIcon.d.ts → svgIcons/FigmaIcon.d.mts} +0 -0
  164. /package/{esm/svgIcons/FigmaIcon.js → svgIcons/FigmaIcon.mjs} +0 -0
  165. /package/{esm/svgIcons/FileDownload.d.ts → svgIcons/FileDownload.d.mts} +0 -0
  166. /package/{esm/svgIcons/FileDownload.js → svgIcons/FileDownload.mjs} +0 -0
  167. /package/{esm/svgIcons/JavaScript.d.ts → svgIcons/JavaScript.d.mts} +0 -0
  168. /package/{esm/svgIcons/JavaScript.js → svgIcons/JavaScript.mjs} +0 -0
  169. /package/{esm/svgIcons/MarkdownIcon.d.ts → svgIcons/MarkdownIcon.d.mts} +0 -0
  170. /package/{esm/svgIcons/MarkdownIcon.js → svgIcons/MarkdownIcon.mjs} +0 -0
  171. /package/{esm/svgIcons/MaterialDesignIcon.d.ts → svgIcons/MaterialDesignIcon.d.mts} +0 -0
  172. /package/{esm/svgIcons/MaterialDesignIcon.js → svgIcons/MaterialDesignIcon.mjs} +0 -0
  173. /package/{esm/svgIcons/SketchIcon.d.ts → svgIcons/SketchIcon.d.mts} +0 -0
  174. /package/{esm/svgIcons/SketchIcon.js → svgIcons/SketchIcon.mjs} +0 -0
  175. /package/{esm/svgIcons/TypeScript.d.ts → svgIcons/TypeScript.d.mts} +0 -0
  176. /package/{esm/svgIcons/TypeScript.js → svgIcons/TypeScript.mjs} +0 -0
  177. /package/{esm/svgIcons/W3CIcon.d.ts → svgIcons/W3CIcon.d.mts} +0 -0
  178. /package/{esm/svgIcons/W3CIcon.js → svgIcons/W3CIcon.mjs} +0 -0
  179. /package/{esm/translations/index.js → translations/index.mjs} +0 -0
  180. /package/{esm/utils/loadScript.d.ts → utils/loadScript.d.mts} +0 -0
  181. /package/{esm/utils/loadScript.js → utils/loadScript.mjs} +0 -0
@@ -2,7 +2,7 @@ import * as React from 'react';
2
2
  import clsx from 'clsx';
3
3
  import { alpha, darken, styled } from '@mui/material/styles';
4
4
  import useForkRef from '@mui/utils/useForkRef';
5
- import { brandingDarkTheme as darkTheme, brandingLightTheme as lightTheme } from "../branding/index.js";
5
+ import { brandingDarkTheme as darkTheme, brandingLightTheme as lightTheme } from "../branding/index.mjs";
6
6
  import { jsx as _jsx } from "react/jsx-runtime";
7
7
  const Root = styled('div')(({
8
8
  theme
@@ -0,0 +1 @@
1
+ export * from "./MarkdownElement.mjs";
@@ -0,0 +1 @@
1
+ export * from "./MarkdownElement.mjs";
@@ -0,0 +1,2 @@
1
+ export { default } from "./NProgressBar.mjs";
2
+ export * from "./NProgressBar.mjs";
@@ -0,0 +1 @@
1
+ export { default } from "./NProgressBar.mjs";
@@ -0,0 +1,13 @@
1
+ import * as React from 'react';
2
+ export interface SectionHeadlineProps {
3
+ alwaysCenter?: boolean;
4
+ description?: React.ReactNode;
5
+ id?: string;
6
+ /**
7
+ * For using with dark background.
8
+ */
9
+ inverted?: boolean;
10
+ overline?: React.ReactNode;
11
+ title: string | React.ReactElement<React.HTMLAttributes<HTMLElement>>;
12
+ }
13
+ export default function SectionHeadline(props: SectionHeadlineProps): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,13 @@
1
+ import * as React from 'react';
2
+ export interface SectionHeadlineProps {
3
+ alwaysCenter?: boolean;
4
+ description?: React.ReactNode;
5
+ id?: string;
6
+ /**
7
+ * For using with dark background.
8
+ */
9
+ inverted?: boolean;
10
+ overline?: React.ReactNode;
11
+ title: string | React.ReactElement<React.HTMLAttributes<HTMLElement>>;
12
+ }
13
+ export default function SectionHeadline(props: SectionHeadlineProps): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,89 @@
1
+ "use strict";
2
+
3
+ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
4
+ var _interopRequireWildcard = require("@babel/runtime/helpers/interopRequireWildcard").default;
5
+ Object.defineProperty(exports, "__esModule", {
6
+ value: true
7
+ });
8
+ exports.default = SectionHeadline;
9
+ var React = _interopRequireWildcard(require("react"));
10
+ var _Box = _interopRequireDefault(require("@mui/material/Box"));
11
+ var _Typography = _interopRequireDefault(require("@mui/material/Typography"));
12
+ var _jsxRuntime = require("react/jsx-runtime");
13
+ function SectionHeadline(props) {
14
+ const {
15
+ alwaysCenter = false,
16
+ description,
17
+ id,
18
+ inverted = false,
19
+ overline,
20
+ title
21
+ } = props;
22
+ return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_Box.default, {
23
+ sx: {
24
+ m: alwaysCenter ? 'auto' : null
25
+ },
26
+ children: [overline && /*#__PURE__*/(0, _jsxRuntime.jsx)(_Typography.default, {
27
+ id: id,
28
+ component: "h2",
29
+ variant: "body2",
30
+ sx: {
31
+ fontWeight: 'bold',
32
+ color: 'primary.main',
33
+ mb: 1,
34
+ ...(alwaysCenter && {
35
+ textAlign: 'center'
36
+ })
37
+ },
38
+ children: overline
39
+ }), typeof title === 'string' ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_Typography.default, {
40
+ variant: "h2",
41
+ sx: theme => ({
42
+ maxWidth: 500,
43
+ ...(inverted ? {
44
+ color: '#fff'
45
+ } : {
46
+ color: 'primaryDark.900',
47
+ ...theme.applyDarkStyles({
48
+ color: 'grey.100'
49
+ })
50
+ }),
51
+ ...(alwaysCenter && {
52
+ textAlign: 'center',
53
+ maxWidth: '100%'
54
+ })
55
+ }),
56
+ children: title
57
+ }) : (/*#__PURE__*/React.cloneElement(title, {
58
+ style: {
59
+ maxWidth: 500,
60
+ ...(alwaysCenter && {
61
+ maxWidth: '100%',
62
+ textAlign: 'center'
63
+ }),
64
+ ...(inverted && {
65
+ color: '#fff'
66
+ })
67
+ }
68
+ })), description && /*#__PURE__*/(0, _jsxRuntime.jsx)(_Typography.default, {
69
+ sx: theme => ({
70
+ mt: 1,
71
+ mb: 3,
72
+ maxWidth: 500,
73
+ ...(inverted ? {
74
+ color: 'grey.400'
75
+ } : {
76
+ color: 'grey.800',
77
+ ...theme.applyDarkStyles({
78
+ color: 'grey.500'
79
+ })
80
+ }),
81
+ ...(alwaysCenter && {
82
+ textAlign: 'center',
83
+ mx: 'auto'
84
+ })
85
+ }),
86
+ children: description
87
+ })]
88
+ });
89
+ }
@@ -0,0 +1,81 @@
1
+ import * as React from 'react';
2
+ import Box from '@mui/material/Box';
3
+ import Typography from '@mui/material/Typography';
4
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
5
+ export default function SectionHeadline(props) {
6
+ const {
7
+ alwaysCenter = false,
8
+ description,
9
+ id,
10
+ inverted = false,
11
+ overline,
12
+ title
13
+ } = props;
14
+ return /*#__PURE__*/_jsxs(Box, {
15
+ sx: {
16
+ m: alwaysCenter ? 'auto' : null
17
+ },
18
+ children: [overline && /*#__PURE__*/_jsx(Typography, {
19
+ id: id,
20
+ component: "h2",
21
+ variant: "body2",
22
+ sx: {
23
+ fontWeight: 'bold',
24
+ color: 'primary.main',
25
+ mb: 1,
26
+ ...(alwaysCenter && {
27
+ textAlign: 'center'
28
+ })
29
+ },
30
+ children: overline
31
+ }), typeof title === 'string' ? /*#__PURE__*/_jsx(Typography, {
32
+ variant: "h2",
33
+ sx: theme => ({
34
+ maxWidth: 500,
35
+ ...(inverted ? {
36
+ color: '#fff'
37
+ } : {
38
+ color: 'primaryDark.900',
39
+ ...theme.applyDarkStyles({
40
+ color: 'grey.100'
41
+ })
42
+ }),
43
+ ...(alwaysCenter && {
44
+ textAlign: 'center',
45
+ maxWidth: '100%'
46
+ })
47
+ }),
48
+ children: title
49
+ }) : (/*#__PURE__*/React.cloneElement(title, {
50
+ style: {
51
+ maxWidth: 500,
52
+ ...(alwaysCenter && {
53
+ maxWidth: '100%',
54
+ textAlign: 'center'
55
+ }),
56
+ ...(inverted && {
57
+ color: '#fff'
58
+ })
59
+ }
60
+ })), description && /*#__PURE__*/_jsx(Typography, {
61
+ sx: theme => ({
62
+ mt: 1,
63
+ mb: 3,
64
+ maxWidth: 500,
65
+ ...(inverted ? {
66
+ color: 'grey.400'
67
+ } : {
68
+ color: 'grey.800',
69
+ ...theme.applyDarkStyles({
70
+ color: 'grey.500'
71
+ })
72
+ }),
73
+ ...(alwaysCenter && {
74
+ textAlign: 'center',
75
+ mx: 'auto'
76
+ })
77
+ }),
78
+ children: description
79
+ })]
80
+ });
81
+ }
@@ -0,0 +1,2 @@
1
+ export * from "./SectionHeadline.mjs";
2
+ export { default } from "./SectionHeadline.mjs";
@@ -0,0 +1,2 @@
1
+ export * from "./SectionHeadline.js";
2
+ export { default } from "./SectionHeadline.js";
@@ -0,0 +1,25 @@
1
+ "use strict";
2
+
3
+ var _interopRequireWildcard = require("@babel/runtime/helpers/interopRequireWildcard").default;
4
+ Object.defineProperty(exports, "__esModule", {
5
+ value: true
6
+ });
7
+ var _exportNames = {};
8
+ Object.defineProperty(exports, "default", {
9
+ enumerable: true,
10
+ get: function () {
11
+ return _SectionHeadline.default;
12
+ }
13
+ });
14
+ var _SectionHeadline = _interopRequireWildcard(require("./SectionHeadline"));
15
+ Object.keys(_SectionHeadline).forEach(function (key) {
16
+ if (key === "default" || key === "__esModule") return;
17
+ if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
18
+ if (key in exports && exports[key] === _SectionHeadline[key]) return;
19
+ Object.defineProperty(exports, key, {
20
+ enumerable: true,
21
+ get: function () {
22
+ return _SectionHeadline[key];
23
+ }
24
+ });
25
+ });
@@ -0,0 +1,2 @@
1
+ export * from "./SectionHeadline.mjs";
2
+ export { default } from "./SectionHeadline.mjs";
@@ -0,0 +1 @@
1
+ export * from "./SectionTitle.mjs";
@@ -0,0 +1 @@
1
+ export * from "./SectionTitle.mjs";
@@ -0,0 +1,92 @@
1
+ import * as React from 'react';
2
+ import PropTypes from 'prop-types';
3
+ export declare const highDensity: {
4
+ components: {
5
+ MuiButton: {
6
+ defaultProps: {
7
+ size: string;
8
+ };
9
+ };
10
+ MuiFilledInput: {
11
+ defaultProps: {
12
+ margin: string;
13
+ };
14
+ };
15
+ MuiFormControl: {
16
+ defaultProps: {
17
+ margin: string;
18
+ };
19
+ };
20
+ MuiFormHelperText: {
21
+ defaultProps: {
22
+ margin: string;
23
+ };
24
+ };
25
+ MuiIconButton: {
26
+ defaultProps: {
27
+ size: string;
28
+ };
29
+ };
30
+ MuiInputBase: {
31
+ defaultProps: {
32
+ margin: string;
33
+ };
34
+ };
35
+ MuiInputLabel: {
36
+ defaultProps: {
37
+ margin: string;
38
+ };
39
+ };
40
+ MuiListItem: {
41
+ defaultProps: {
42
+ dense: boolean;
43
+ };
44
+ };
45
+ MuiOutlinedInput: {
46
+ defaultProps: {
47
+ margin: string;
48
+ };
49
+ };
50
+ MuiFab: {
51
+ defaultProps: {
52
+ size: string;
53
+ };
54
+ };
55
+ MuiTable: {
56
+ defaultProps: {
57
+ size: string;
58
+ };
59
+ };
60
+ MuiTextField: {
61
+ defaultProps: {
62
+ margin: string;
63
+ };
64
+ };
65
+ MuiToolbar: {
66
+ defaultProps: {
67
+ variant: string;
68
+ };
69
+ };
70
+ };
71
+ };
72
+ export declare const DispatchContext: React.Context<React.ActionDispatch<any>>;
73
+ export declare const ThemeOptionsContext: React.Context<{
74
+ dense: boolean;
75
+ direction: "ltr" | "rtl";
76
+ paletteMode: "light" | "dark";
77
+ }>;
78
+ export declare function ThemeProvider(props: React.PropsWithChildren): import("react/jsx-runtime").JSX.Element;
79
+ export declare namespace ThemeProvider {
80
+ var propTypes: {
81
+ children: PropTypes.Requireable<PropTypes.ReactNodeLike>;
82
+ };
83
+ }
84
+ /**
85
+ * @returns {(nextOptions: Partial<typeof themeInitialOptions>) => void}
86
+ */
87
+ export declare function useChangeTheme(): (options: any) => void;
88
+ export declare function useColorSchemeShim(): {
89
+ mode: string | null;
90
+ systemMode: string;
91
+ setMode: React.Dispatch<React.SetStateAction<string | null>>;
92
+ };
@@ -0,0 +1,92 @@
1
+ import * as React from 'react';
2
+ import PropTypes from 'prop-types';
3
+ export declare const highDensity: {
4
+ components: {
5
+ MuiButton: {
6
+ defaultProps: {
7
+ size: string;
8
+ };
9
+ };
10
+ MuiFilledInput: {
11
+ defaultProps: {
12
+ margin: string;
13
+ };
14
+ };
15
+ MuiFormControl: {
16
+ defaultProps: {
17
+ margin: string;
18
+ };
19
+ };
20
+ MuiFormHelperText: {
21
+ defaultProps: {
22
+ margin: string;
23
+ };
24
+ };
25
+ MuiIconButton: {
26
+ defaultProps: {
27
+ size: string;
28
+ };
29
+ };
30
+ MuiInputBase: {
31
+ defaultProps: {
32
+ margin: string;
33
+ };
34
+ };
35
+ MuiInputLabel: {
36
+ defaultProps: {
37
+ margin: string;
38
+ };
39
+ };
40
+ MuiListItem: {
41
+ defaultProps: {
42
+ dense: boolean;
43
+ };
44
+ };
45
+ MuiOutlinedInput: {
46
+ defaultProps: {
47
+ margin: string;
48
+ };
49
+ };
50
+ MuiFab: {
51
+ defaultProps: {
52
+ size: string;
53
+ };
54
+ };
55
+ MuiTable: {
56
+ defaultProps: {
57
+ size: string;
58
+ };
59
+ };
60
+ MuiTextField: {
61
+ defaultProps: {
62
+ margin: string;
63
+ };
64
+ };
65
+ MuiToolbar: {
66
+ defaultProps: {
67
+ variant: string;
68
+ };
69
+ };
70
+ };
71
+ };
72
+ export declare const DispatchContext: React.Context<React.ActionDispatch<any>>;
73
+ export declare const ThemeOptionsContext: React.Context<{
74
+ dense: boolean;
75
+ direction: "ltr" | "rtl";
76
+ paletteMode: "light" | "dark";
77
+ }>;
78
+ export declare function ThemeProvider(props: React.PropsWithChildren): import("react/jsx-runtime").JSX.Element;
79
+ export declare namespace ThemeProvider {
80
+ var propTypes: {
81
+ children: PropTypes.Requireable<PropTypes.ReactNodeLike>;
82
+ };
83
+ }
84
+ /**
85
+ * @returns {(nextOptions: Partial<typeof themeInitialOptions>) => void}
86
+ */
87
+ export declare function useChangeTheme(): (options: any) => void;
88
+ export declare function useColorSchemeShim(): {
89
+ mode: string | null;
90
+ systemMode: string;
91
+ setMode: React.Dispatch<React.SetStateAction<string | null>>;
92
+ };
@@ -0,0 +1,212 @@
1
+ "use strict";
2
+
3
+ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
4
+ var _interopRequireWildcard = require("@babel/runtime/helpers/interopRequireWildcard").default;
5
+ Object.defineProperty(exports, "__esModule", {
6
+ value: true
7
+ });
8
+ exports.ThemeOptionsContext = exports.DispatchContext = void 0;
9
+ exports.ThemeProvider = ThemeProvider;
10
+ exports.highDensity = void 0;
11
+ exports.useChangeTheme = useChangeTheme;
12
+ exports.useColorSchemeShim = useColorSchemeShim;
13
+ var React = _interopRequireWildcard(require("react"));
14
+ var _propTypes = _interopRequireDefault(require("prop-types"));
15
+ var _styles = require("@mui/material/styles");
16
+ var _utils = require("@mui/material/utils");
17
+ var _useMediaQuery = _interopRequireDefault(require("@mui/material/useMediaQuery"));
18
+ var _useLocalStorageState = _interopRequireDefault(require("@mui/utils/useLocalStorageState"));
19
+ var _useLazyCSS = _interopRequireDefault(require("../useLazyCSS"));
20
+ var _branding = require("../branding");
21
+ var _jsxRuntime = require("react/jsx-runtime");
22
+ const themeInitialOptions = {
23
+ dense: false,
24
+ direction: 'ltr',
25
+ paletteMode: 'light'
26
+ };
27
+ const highDensity = exports.highDensity = {
28
+ components: {
29
+ MuiButton: {
30
+ defaultProps: {
31
+ size: 'small'
32
+ }
33
+ },
34
+ MuiFilledInput: {
35
+ defaultProps: {
36
+ margin: 'dense'
37
+ }
38
+ },
39
+ MuiFormControl: {
40
+ defaultProps: {
41
+ margin: 'dense'
42
+ }
43
+ },
44
+ MuiFormHelperText: {
45
+ defaultProps: {
46
+ margin: 'dense'
47
+ }
48
+ },
49
+ MuiIconButton: {
50
+ defaultProps: {
51
+ size: 'small'
52
+ }
53
+ },
54
+ MuiInputBase: {
55
+ defaultProps: {
56
+ margin: 'dense'
57
+ }
58
+ },
59
+ MuiInputLabel: {
60
+ defaultProps: {
61
+ margin: 'dense'
62
+ }
63
+ },
64
+ MuiListItem: {
65
+ defaultProps: {
66
+ dense: true
67
+ }
68
+ },
69
+ MuiOutlinedInput: {
70
+ defaultProps: {
71
+ margin: 'dense'
72
+ }
73
+ },
74
+ MuiFab: {
75
+ defaultProps: {
76
+ size: 'small'
77
+ }
78
+ },
79
+ MuiTable: {
80
+ defaultProps: {
81
+ size: 'small'
82
+ }
83
+ },
84
+ MuiTextField: {
85
+ defaultProps: {
86
+ margin: 'dense'
87
+ }
88
+ },
89
+ MuiToolbar: {
90
+ defaultProps: {
91
+ variant: 'dense'
92
+ }
93
+ }
94
+ }
95
+ };
96
+ const DispatchContext = exports.DispatchContext = /*#__PURE__*/React.createContext(() => {
97
+ throw new Error('Forgot to wrap component in `ThemeProvider`');
98
+ });
99
+ if (process.env.NODE_ENV !== 'production') {
100
+ DispatchContext.displayName = 'ThemeDispatchContext';
101
+ }
102
+ const ThemeOptionsContext = exports.ThemeOptionsContext = /*#__PURE__*/React.createContext(themeInitialOptions);
103
+ if (process.env.NODE_ENV !== 'production') {
104
+ ThemeOptionsContext.displayName = 'ThemeOptionsContext';
105
+ }
106
+ function ThemeProvider(props) {
107
+ const {
108
+ children
109
+ } = props;
110
+ const [themeOptions, dispatch] = React.useReducer((state, action) => {
111
+ switch (action.type) {
112
+ case 'SET_DENSE':
113
+ return {
114
+ ...state,
115
+ dense: action.payload
116
+ };
117
+ case 'RESET_DENSITY':
118
+ return {
119
+ ...state,
120
+ dense: themeInitialOptions.dense
121
+ };
122
+ case 'CHANGE':
123
+ // No value changed
124
+ if ((!action.payload.paletteMode || action.payload.paletteMode === state.paletteMode) && (!action.payload.direction || action.payload.direction === state.direction)) {
125
+ return state;
126
+ }
127
+ return {
128
+ ...state,
129
+ paletteMode: action.payload.paletteMode || state.paletteMode,
130
+ direction: action.payload.direction || state.direction
131
+ };
132
+ default:
133
+ throw new Error(`Unrecognized type ${action.type}`);
134
+ }
135
+ }, themeInitialOptions);
136
+ const {
137
+ direction,
138
+ paletteMode
139
+ } = themeOptions;
140
+ (0, _useLazyCSS.default)('/static/styles/prism-okaidia.css', '#prismjs');
141
+
142
+ // TODO replace with useColorScheme once all pages support css vars
143
+ const {
144
+ mode,
145
+ systemMode
146
+ } = useColorSchemeShim();
147
+ const calculatedMode = mode === 'system' ? systemMode : mode;
148
+ (0, _utils.unstable_useEnhancedEffect)(() => {
149
+ dispatch({
150
+ type: 'CHANGE',
151
+ payload: {
152
+ paletteMode: calculatedMode
153
+ }
154
+ });
155
+ }, [calculatedMode]);
156
+ (0, _utils.unstable_useEnhancedEffect)(() => {
157
+ document.body.setAttribute('dir', direction);
158
+ }, [direction]);
159
+ (0, _utils.unstable_useEnhancedEffect)(() => {
160
+ // To support light and dark mode images in the docs
161
+ if (paletteMode === 'dark') {
162
+ document.body.classList.remove('mode-light');
163
+ document.body.classList.add('mode-dark');
164
+ } else {
165
+ document.body.classList.remove('mode-dark');
166
+ document.body.classList.add('mode-light');
167
+ }
168
+ const metas = document.querySelectorAll('meta[name="theme-color"]');
169
+ metas.forEach(meta => {
170
+ meta.setAttribute('content', (0, _branding.getMetaThemeColor)(paletteMode));
171
+ });
172
+ }, [paletteMode]);
173
+ React.useEffect(() => {
174
+ // Expose the theme as a global variable so people can play with it.
175
+ window.createTheme = _styles.createTheme;
176
+ }, []);
177
+ return /*#__PURE__*/(0, _jsxRuntime.jsx)(ThemeOptionsContext.Provider, {
178
+ value: themeOptions,
179
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(DispatchContext.Provider, {
180
+ value: dispatch,
181
+ children: children
182
+ })
183
+ });
184
+ }
185
+ process.env.NODE_ENV !== "production" ? ThemeProvider.propTypes = {
186
+ children: _propTypes.default.node
187
+ } : void 0;
188
+
189
+ /**
190
+ * @returns {(nextOptions: Partial<typeof themeInitialOptions>) => void}
191
+ */
192
+ function useChangeTheme() {
193
+ const dispatch = React.useContext(DispatchContext);
194
+ return React.useCallback(options => dispatch({
195
+ type: 'CHANGE',
196
+ payload: options
197
+ }), [dispatch]);
198
+ }
199
+
200
+ // TODO: remove once all pages support css vars and replace call sites with useColorScheme()
201
+ function useColorSchemeShim() {
202
+ const [mode, setMode] = (0, _useLocalStorageState.default)('mui-mode', 'system');
203
+ const prefersDarkMode = (0, _useMediaQuery.default)('(prefers-color-scheme: dark)', {
204
+ noSsr: true
205
+ });
206
+ const systemMode = prefersDarkMode ? 'dark' : 'light';
207
+ return {
208
+ mode,
209
+ systemMode,
210
+ setMode
211
+ };
212
+ }