-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #37 from newrelic/kpeet/cumulativeChart
feat: add cumulative chart
- Loading branch information
Showing
10 changed files
with
411 additions
and
47 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,72 @@ | ||
import React from 'react'; | ||
|
||
import { | ||
Card, | ||
CardHeader, | ||
CardBody, | ||
HeadingText, | ||
BlockText, | ||
Spacing | ||
} from 'nr1'; | ||
|
||
import RenderPropertyInfo from '../../shared/PropertyInfo'; | ||
|
||
const properties = require('./nr1.json'); | ||
|
||
export default function Docs() { | ||
return ( | ||
<div style={{ textAlign: 'left' }}> | ||
<HeadingText type={HeadingText.TYPE.HEADING_2}>Documentation</HeadingText> | ||
<Card collapsible> | ||
<CardHeader title="Overview" /> | ||
<CardBody style={{ marginLeft: '35px' }}> | ||
<BlockText spacingType={[BlockText.SPACING_TYPE.MEDIUM]}> | ||
Use the Cumulative Chart to see running totals, or the total sum of | ||
a given data set as it grows with time. | ||
<br /> | ||
<br /> | ||
The chart supports Line & Area chart types. | ||
</BlockText> | ||
</CardBody> | ||
</Card> | ||
<Card collapsible defaultCollapsed> | ||
<CardHeader title="Query Syntax" /> | ||
<CardBody style={{ marginLeft: '35px' }}> | ||
<BlockText spacingType={[BlockText.SPACING_TYPE.MEDIUM]}> | ||
In order to populate the chart, there are a few requirements: | ||
<Spacing type={[Spacing.TYPE.MEDIUM, Spacing.TYPE.EXTRA_LARGE]}> | ||
<ul> | ||
<li>At least 1 timeseries query</li> | ||
<li> | ||
Timeseries queries should contain the <code>TIMESERIES</code>{' '} | ||
clause | ||
</li> | ||
</ul> | ||
</Spacing> | ||
<Spacing type={[Spacing.TYPE.MEDIUM]}> | ||
<div> | ||
A valid timeseries query for the chart could look like this:{' '} | ||
</div> | ||
</Spacing> | ||
<Spacing type={[Spacing.TYPE.MEDIUM, Spacing.TYPE.LARGE]}> | ||
<code>SELECT count(*) FROM Transaction TIMESERIES</code> | ||
</Spacing> | ||
</BlockText> | ||
</CardBody> | ||
</Card> | ||
|
||
<Card collapsible defaultCollapsed> | ||
<CardHeader title="Properties" /> | ||
<CardBody style={{ marginLeft: '35px' }}> | ||
{properties.configuration | ||
.filter(c => c.name !== 'showDocs') | ||
.map(config => { | ||
return RenderPropertyInfo(config, false, {}); | ||
})} | ||
</CardBody> | ||
</Card> | ||
|
||
<hr /> | ||
</div> | ||
); | ||
} |
Oops, something went wrong.