Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Add DynamicRadar component. #207

Merged
merged 1 commit into from
Aug 13, 2021

Conversation

tyn1998
Copy link
Member

@tyn1998 tyn1998 commented Aug 12, 2021

Purpose

This PR implements the "Dynamic Radar" feature requested by #205.

Component description

The DynamicRadar component consists of 3 sub components: Radar, SimpleTable and ControlBar. These components benefit from the following technologies:

DynamicRadar is really easy to use and provides features like:

  • light & dark themes
  • customizable sizes
  • dynamic & interactive

Code structure

image

Usage example

import DynamicRadar from '../../components/DynamicRadar/DynamicRadar';

const indicators = ['commit', 'issue', 'PR', 'comment', 'star', 'fork', 'contributor', ];

let data = [
  {
    date: '2021/1/1',
    values: [82, 120, 31, 360, 20, 15, 8],
  },
  ...
];

const Demo = () => {
  return (
    <DynamicRadar theme='light' height={300} width={500} indicators={indicators} data={data}>
  )
}

Screenshots

This .gif shows what "dynamic" means for:
Peek 2021-08-11 21-50

This .png shows two themes with configurable sizes.
image

Proposed changes

Types of changes

  • Bugfix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation Update (if none of the other choices apply)

Checklist

  • I have read the CONTRIBUTING doc
  • I have signed the CLA
  • Lint and unit tests pass locally with my changes
  • I have added tests that prove my fix is effective or that my feature works
  • I have added necessary documentation (if appropriate)

Further comments (Optional)

If you are interested in how this component is developed, go and look for 08-02~08-11.

This component consists of 3 sub components:
 - Radar
 - SimpleTable
 - ControlBar
Copy link
Contributor

@heming6666 heming6666 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great work! Thanks @tyn1998

/approve

@menbotics menbotics bot added the pull/approved If a pull is approved, it will be automatically merged label Aug 13, 2021
@menbotics menbotics bot merged commit 6b41263 into hypertrons:master Aug 13, 2021
@tyn1998 tyn1998 deleted the dynamic-radar branch August 13, 2021 01:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pull/approved If a pull is approved, it will be automatically merged
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants