diff options
Diffstat (limited to 'docs/src/components/ClassPropertyRef.tsx')
-rw-r--r-- | docs/src/components/ClassPropertyRef.tsx | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/docs/src/components/ClassPropertyRef.tsx b/docs/src/components/ClassPropertyRef.tsx new file mode 100644 index 00000000..46664c4c --- /dev/null +++ b/docs/src/components/ClassPropertyRef.tsx @@ -0,0 +1,26 @@ +import React from "react"; + +interface ClassPropertyRefProps { + name: string; + details: string; + required: boolean; +} + +export default function ClassPropertyRef(props: ClassPropertyRefProps) { + const details = JSON.parse(props.details); + + return ( + <> + <div> + <h4 style={{ display: "inline-block", marginRight: "10px" }}> + {props.name} + </h4> + <span style={{ color: "red", fontSize: "11px", marginRight: "4px" }}> + {props.required && "REQUIRED"} + </span> + <span>{details.type && `(${details.type})`}</span> + </div> + <p>{details.description}</p> + </> + ); +} |