Skip to content
This repository has been archived by the owner on Nov 29, 2023. It is now read-only.

Commit

Permalink
Merge pull request #43 from lars-reimann/FeedbackLeereParamDokumentation
Browse files Browse the repository at this point in the history
"No Documentation available" Wenn docstring leer
  • Loading branch information
Vengos authored Jun 17, 2021
2 parents 45f3bd9 + 41c7cbb commit 36b827f
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion client/src/Components/ParameterView/ParameterNode.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@ import { Dropdown } from "react-bootstrap";
type ParameterProps = {inputParameter: PythonParameter}

const ParameterNode = ({inputParameter}: ParameterProps) => {

const hasDescription = !!inputParameter.docstring;

return (
<div className="parametersList">
<span className="parameter-header">
Expand All @@ -21,7 +24,15 @@ const ParameterNode = ({inputParameter}: ParameterProps) => {
</Dropdown.Menu>
</Dropdown>
</span>
<DocumentationText inputText={inputParameter?.docstring}/>
{
hasDescription &&
<DocumentationText inputText={inputParameter?.docstring}/>
}
{
!hasDescription &&
<p>No Documentation available</p>
}

</div>
);
};
Expand Down

0 comments on commit 36b827f

Please sign in to comment.