Skip to content

Commit

Permalink
hiding chart unless there is data while I'm at it
Browse files Browse the repository at this point in the history
  • Loading branch information
krachwal committed May 21, 2024
1 parent 6d8a4c9 commit 06adb63
Showing 1 changed file with 16 additions and 12 deletions.
28 changes: 16 additions & 12 deletions react-frontend/src/components/Charts.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@ function Charts({ a_n, b_n, limit, symbol, convergesTo, deltaData, toggleDisplay
return text;
};

// we get constant/symbol metadata from both wolfram and LIReC and we need to consolidate into
// we get constant/symbol metadata from both wolfram and LIReC and we need to consolidate into
// a unified format to prevent duplicates and line up the attribute names
const polishMetadata = (input: WolframMetadata) => {
let name = wolframTextCleanup(input.text);
Expand Down Expand Up @@ -336,17 +336,21 @@ function Charts({ a_n, b_n, limit, symbol, convergesTo, deltaData, toggleDisplay
) : (
''
)}
<div className="top-padding plot-container">
<p>
Delta is a measure of the irrationality of a number (read more about it{' '}
<a href="https://www.ramanujanmachine.com/the-mathematics-of-polynomial-continued-fractions/irrationality-testing/">
here
</a>
). The given Polynomial Continued Fraction produces the following finite-depth
estimations for Delta:
</p>
<ScatterPlot id="delta_chart" data={deltaData} />
</div>
{deltaData && deltaData?.length > 0 ? (
<div className="top-padding plot-container">
<p>
Delta is a measure of the irrationality of a number (read more about it{' '}
<a href="https://www.ramanujanmachine.com/the-mathematics-of-polynomial-continued-fractions/irrationality-testing/">
here
</a>
). The given Polynomial Continued Fraction produces the following finite-depth
estimations for Delta:
</p>
<ScatterPlot id="delta_chart" data={deltaData} />
</div>
) : (
''
)}
</MathJaxContext>
<button
onClick={() => {
Expand Down

0 comments on commit 06adb63

Please sign in to comment.