File tree Expand file tree Collapse file tree 2 files changed +47
-1
lines changed
Expand file tree Collapse file tree 2 files changed +47
-1
lines changed Original file line number Diff line number Diff line change @@ -21,7 +21,6 @@ const config: Config = {
2121 deploymentBranch : 'gh-pages' ,
2222
2323 onBrokenLinks : 'throw' ,
24- onBrokenMarkdownLinks : 'warn' ,
2524
2625 // Even if you don't use internationalization, you can use this field to set
2726 // useful metadata like html lang. For example, if your site is Chinese, you
@@ -61,6 +60,9 @@ const config: Config = {
6160
6261 markdown : {
6362 mermaid : true ,
63+ hooks : {
64+ onBrokenMarkdownLinks : 'warn' ,
65+ } ,
6466 } ,
6567 themes : [ '@docusaurus/theme-mermaid' ] ,
6668
Original file line number Diff line number Diff line change 1+ import React from 'react' ;
2+ import DefaultAdmonitionTypes from '@theme-original/Admonition/Types' ;
3+
4+ function PerformanceAdmonition ( props ) {
5+ return (
6+ < DefaultAdmonitionTypes . tip { ...props } title = { props . title || 'Performance' } >
7+ { props . children }
8+ </ DefaultAdmonitionTypes . tip >
9+ ) ;
10+ }
11+
12+ function FromXunitAdmonition ( props ) {
13+ return (
14+ < DefaultAdmonitionTypes . info { ...props } title = { props . title || 'Coming from xUnit' } >
15+ { props . children }
16+ </ DefaultAdmonitionTypes . info >
17+ ) ;
18+ }
19+
20+ function FromNunitAdmonition ( props ) {
21+ return (
22+ < DefaultAdmonitionTypes . info { ...props } title = { props . title || 'Coming from NUnit' } >
23+ { props . children }
24+ </ DefaultAdmonitionTypes . info >
25+ ) ;
26+ }
27+
28+ function FromMstestAdmonition ( props ) {
29+ return (
30+ < DefaultAdmonitionTypes . info { ...props } title = { props . title || 'Coming from MSTest' } >
31+ { props . children }
32+ </ DefaultAdmonitionTypes . info >
33+ ) ;
34+ }
35+
36+ const AdmonitionTypes = {
37+ ...DefaultAdmonitionTypes ,
38+ 'performance' : PerformanceAdmonition ,
39+ 'from-xunit' : FromXunitAdmonition ,
40+ 'from-nunit' : FromNunitAdmonition ,
41+ 'from-mstest' : FromMstestAdmonition ,
42+ } ;
43+
44+ export default AdmonitionTypes ;
You can’t perform that action at this time.
0 commit comments