@docusaurus/theme-classic 0.0.0-5071 → 0.0.0-5077
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/lib/theme/BlogPostPage/index.js +1 -3
- package/lib/theme/DocCardList/index.js +1 -1
- package/lib/theme/DocItem/index.js +1 -2
- package/lib/theme/MDXPage/index.js +1 -1
- package/package.json +18 -14
- package/src/theme/BlogPostPage/index.tsx +1 -3
- package/src/theme/DocCardList/index.tsx +1 -1
- package/src/theme/DocItem/index.tsx +1 -2
- package/src/theme/MDXPage/index.tsx +1 -1
- package/src/theme-classic.d.ts +0 -2
|
@@ -61,9 +61,7 @@ function BlogPostPageContent(props) {
|
|
|
61
61
|
<BlogLayout
|
|
62
62
|
sidebar={sidebar}
|
|
63
63
|
toc={
|
|
64
|
-
!hideTableOfContents &&
|
|
65
|
-
BlogPostContents.toc &&
|
|
66
|
-
BlogPostContents.toc.length > 0 ? (
|
|
64
|
+
!hideTableOfContents && BlogPostContents.toc.length > 0 ? (
|
|
67
65
|
<TOC
|
|
68
66
|
toc={BlogPostContents.toc}
|
|
69
67
|
minHeadingLevel={tocMinHeadingLevel}
|
|
@@ -22,7 +22,7 @@ export default function DocCardList({items, className}) {
|
|
|
22
22
|
<section className={clsx('row', className)}>
|
|
23
23
|
{filterItems(items).map((item, index) => (
|
|
24
24
|
<article key={index} className="col col--6 margin-bottom--lg">
|
|
25
|
-
<DocCard
|
|
25
|
+
<DocCard item={item} />
|
|
26
26
|
</article>
|
|
27
27
|
))}
|
|
28
28
|
</section>
|
|
@@ -46,8 +46,7 @@ function DocItemContent(props) {
|
|
|
46
46
|
const shouldAddTitle =
|
|
47
47
|
!hideTitle && typeof DocContent.contentTitle === 'undefined';
|
|
48
48
|
const windowSize = useWindowSize();
|
|
49
|
-
const canRenderTOC =
|
|
50
|
-
!hideTableOfContents && DocContent.toc && DocContent.toc.length > 0;
|
|
49
|
+
const canRenderTOC = !hideTableOfContents && DocContent.toc.length > 0;
|
|
51
50
|
const renderTocDesktop =
|
|
52
51
|
canRenderTOC && (windowSize === 'desktop' || windowSize === 'ssr');
|
|
53
52
|
return (
|
|
@@ -37,7 +37,7 @@ export default function MDXPage(props) {
|
|
|
37
37
|
<MDXPageContent />
|
|
38
38
|
</MDXContent>
|
|
39
39
|
</div>
|
|
40
|
-
{!hideTableOfContents && MDXPageContent.toc && (
|
|
40
|
+
{!hideTableOfContents && MDXPageContent.toc.length > 0 && (
|
|
41
41
|
<div className="col col--2">
|
|
42
42
|
<TOC
|
|
43
43
|
toc={MDXPageContent.toc}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@docusaurus/theme-classic",
|
|
3
|
-
"version": "0.0.0-
|
|
3
|
+
"version": "0.0.0-5077",
|
|
4
4
|
"description": "Classic theme for Docusaurus",
|
|
5
5
|
"main": "lib/index.js",
|
|
6
6
|
"types": "src/theme-classic.d.ts",
|
|
@@ -20,15 +20,18 @@
|
|
|
20
20
|
"copy:watch": "node ../../admin/scripts/copyUntypedFiles.js --watch"
|
|
21
21
|
},
|
|
22
22
|
"dependencies": {
|
|
23
|
-
"@docusaurus/core": "0.0.0-
|
|
24
|
-
"@docusaurus/
|
|
25
|
-
"@docusaurus/
|
|
26
|
-
"@docusaurus/plugin-content-
|
|
27
|
-
"@docusaurus/
|
|
28
|
-
"@docusaurus/
|
|
29
|
-
"@docusaurus/
|
|
30
|
-
"@docusaurus/
|
|
31
|
-
"@docusaurus/
|
|
23
|
+
"@docusaurus/core": "0.0.0-5077",
|
|
24
|
+
"@docusaurus/mdx-loader": "0.0.0-5077",
|
|
25
|
+
"@docusaurus/module-type-aliases": "0.0.0-5077",
|
|
26
|
+
"@docusaurus/plugin-content-blog": "0.0.0-5077",
|
|
27
|
+
"@docusaurus/plugin-content-docs": "0.0.0-5077",
|
|
28
|
+
"@docusaurus/plugin-content-pages": "0.0.0-5077",
|
|
29
|
+
"@docusaurus/theme-common": "0.0.0-5077",
|
|
30
|
+
"@docusaurus/theme-translations": "0.0.0-5077",
|
|
31
|
+
"@docusaurus/types": "0.0.0-5077",
|
|
32
|
+
"@docusaurus/utils": "0.0.0-5077",
|
|
33
|
+
"@docusaurus/utils-common": "0.0.0-5077",
|
|
34
|
+
"@docusaurus/utils-validation": "0.0.0-5077",
|
|
32
35
|
"@mdx-js/react": "^1.6.22",
|
|
33
36
|
"clsx": "^1.1.1",
|
|
34
37
|
"copy-text-to-clipboard": "^3.0.1",
|
|
@@ -40,11 +43,12 @@
|
|
|
40
43
|
"prismjs": "^1.28.0",
|
|
41
44
|
"react-router-dom": "^5.3.3",
|
|
42
45
|
"rtlcss": "^3.5.0",
|
|
43
|
-
"tslib": "^2.4.0"
|
|
46
|
+
"tslib": "^2.4.0",
|
|
47
|
+
"utility-types": "^3.10.0"
|
|
44
48
|
},
|
|
45
49
|
"devDependencies": {
|
|
46
|
-
"@docusaurus/module-type-aliases": "
|
|
47
|
-
"@docusaurus/types": "
|
|
50
|
+
"@docusaurus/module-type-aliases": "2.0.0-beta.21",
|
|
51
|
+
"@docusaurus/types": "2.0.0-beta.21",
|
|
48
52
|
"@types/mdx-js__react": "^1.5.5",
|
|
49
53
|
"@types/nprogress": "^0.2.0",
|
|
50
54
|
"@types/prismjs": "^1.26.0",
|
|
@@ -60,5 +64,5 @@
|
|
|
60
64
|
"engines": {
|
|
61
65
|
"node": ">=16.14"
|
|
62
66
|
},
|
|
63
|
-
"gitHead": "
|
|
67
|
+
"gitHead": "c94e9b3454e0518e25d5a8cdf85278a491125b19"
|
|
64
68
|
}
|
|
@@ -65,9 +65,7 @@ function BlogPostPageContent(props: Props): JSX.Element {
|
|
|
65
65
|
<BlogLayout
|
|
66
66
|
sidebar={sidebar}
|
|
67
67
|
toc={
|
|
68
|
-
!hideTableOfContents &&
|
|
69
|
-
BlogPostContents.toc &&
|
|
70
|
-
BlogPostContents.toc.length > 0 ? (
|
|
68
|
+
!hideTableOfContents && BlogPostContents.toc.length > 0 ? (
|
|
71
69
|
<TOC
|
|
72
70
|
toc={BlogPostContents.toc}
|
|
73
71
|
minHeadingLevel={tocMinHeadingLevel}
|
|
@@ -27,7 +27,7 @@ export default function DocCardList({items, className}: Props): JSX.Element {
|
|
|
27
27
|
<section className={clsx('row', className)}>
|
|
28
28
|
{filterItems(items).map((item, index) => (
|
|
29
29
|
<article key={index} className="col col--6 margin-bottom--lg">
|
|
30
|
-
<DocCard
|
|
30
|
+
<DocCard item={item} />
|
|
31
31
|
</article>
|
|
32
32
|
))}
|
|
33
33
|
</section>
|
|
@@ -55,8 +55,7 @@ function DocItemContent(props: Props): JSX.Element {
|
|
|
55
55
|
|
|
56
56
|
const windowSize = useWindowSize();
|
|
57
57
|
|
|
58
|
-
const canRenderTOC =
|
|
59
|
-
!hideTableOfContents && DocContent.toc && DocContent.toc.length > 0;
|
|
58
|
+
const canRenderTOC = !hideTableOfContents && DocContent.toc.length > 0;
|
|
60
59
|
|
|
61
60
|
const renderTocDesktop =
|
|
62
61
|
canRenderTOC && (windowSize === 'desktop' || windowSize === 'ssr');
|
|
@@ -42,7 +42,7 @@ export default function MDXPage(props: Props): JSX.Element {
|
|
|
42
42
|
<MDXPageContent />
|
|
43
43
|
</MDXContent>
|
|
44
44
|
</div>
|
|
45
|
-
{!hideTableOfContents && MDXPageContent.toc && (
|
|
45
|
+
{!hideTableOfContents && MDXPageContent.toc.length > 0 && (
|
|
46
46
|
<div className="col col--2">
|
|
47
47
|
<TOC
|
|
48
48
|
toc={MDXPageContent.toc}
|
package/src/theme-classic.d.ts
CHANGED
|
@@ -328,8 +328,6 @@ declare module '@theme/DocSidebar' {
|
|
|
328
328
|
readonly sidebar: readonly PropSidebarItem[];
|
|
329
329
|
readonly onCollapse: () => void;
|
|
330
330
|
readonly isHidden: boolean;
|
|
331
|
-
// MobileSecondaryFilter expects Record<string, unknown>
|
|
332
|
-
readonly [key: string]: unknown;
|
|
333
331
|
}
|
|
334
332
|
|
|
335
333
|
export default function DocSidebar(props: Props): JSX.Element;
|