File tree Expand file tree Collapse file tree 1 file changed +12
-1
lines changed
packages/docusaurus-theme-openapi-docs/src/theme/ParamsDetails Expand file tree Collapse file tree 1 file changed +12
-1
lines changed Original file line number Diff line number Diff line change 7
7
8
8
import React from "react" ;
9
9
10
+ import BrowserOnly from "@docusaurus/BrowserOnly" ;
10
11
import Details from "@theme/Details" ;
11
12
import ParamsItem from "@theme/ParamsItem" ;
12
13
13
- const ParamsDetails = ( { parameters } : { parameters : any [ ] } ) => {
14
+ interface Props {
15
+ parameters : any [ ] ;
16
+ }
17
+
18
+ const ParamsDetailsComponent : React . FC < Props > = ( { parameters } ) => {
14
19
const types = [ "path" , "query" , "header" , "cookie" ] ;
15
20
16
21
return (
@@ -62,4 +67,10 @@ const ParamsDetails = ({ parameters }: { parameters: any[] }) => {
62
67
) ;
63
68
} ;
64
69
70
+ const ParamsDetails : React . FC < Props > = ( props ) => (
71
+ < BrowserOnly fallback = { < div > Loading...</ div > } >
72
+ { ( ) => < ParamsDetailsComponent { ...props } /> }
73
+ </ BrowserOnly >
74
+ ) ;
75
+
65
76
export default ParamsDetails ;
You can’t perform that action at this time.
0 commit comments