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

D3fc plugin #420

Merged
merged 256 commits into from
Feb 26, 2019
Merged

D3fc plugin #420

merged 256 commits into from
Feb 26, 2019

Conversation

redbearsam
Copy link
Contributor

@redbearsam redbearsam commented Feb 7, 2019

Update: ready for review.

A plugin that uses D3/d3fc as an alternative charting solution to HighCharts.

The plugin is not feature complete. Development continues.

Functionality:

  • Y Bar, X Bar, Y Line, X/Y Scatter
  • Group By
  • Split By
  • Sort and Filter
  • Multiple columns/series
  • Legend with toggle on/off and paging
  • Hover tooltips
  • Dark and Light themes
  • Additional plug-in, doesn't impact existing HighCharts plug-ins

Known issues:

  • Axes do not handle lots of values and do not automatically prevent label overlaps.
  • When there are groupBys in use the labels are not split across layers and grouped.

Demonstrating The Plugin:

It should be possible to run the pre-existing examples with the new d3fc chart variants selected. These are called [d3fc] Y Bar Chart and [d3fc] X Bar Chart. There is also a new example accessible from the simple example index page titled Superstore example using D3FC Bar/Column charts that is configured to use the d3fc Y Bar Chart by default.

All changes are within the new perspective-viewer-d3fc package with the exception of:

  1. The changes to the simple examples.
  2. A modification to the material.dark.less theme.
  3. Addition of the d3fc build directory to the DEFAULT_ASSETS array constant in perspective.node.js.

jburton-scottlogic and others added 30 commits February 6, 2019 11:19
- added default blue color to non-split-by bar graph.
- added grid behind split-by bar graph.
- ticks and labels on y axis brought into line with highcharts (ticks surrounding bars rather than pointing to them)
- renderChart and renderStackedChart method combined into one.
- discrete operations refactored into discrete methods for code legibility.
- improved logic for reading axis labels, particularly in the case that there are multiple.
- encapsulated chart config in discrete function for consistency.
- moved axis labelling inside styling function.
- remove hardcoded styling of axes' colors.
- prevent labels on y axis underlapping data zone.
- also switched crossLabel and mainLabel to be correct
- pass more specific parameters into interpretData function
Ro4052 and others added 27 commits February 13, 2019 13:42
Preserves the meaning of "crossValue" and "mainValue" so that we'll be able to use those values with the tooltip component without too many changes
The issue was actually with trying to create an empty bar series and associating a tooltip with it, which didn't check that it actually had a node to use.
Separated the scrollable code from the perspective-d3fc code to create a standalone "scrollable" legend component
Cleaner axis styling with more readable text
More interactive tooltip behaviour
Some styling and tooltip hover changes
@redbearsam redbearsam changed the title D3fc plugin - PROOF OF CONCEPT ONLY - NOT SUITABLE FOR MERGING D3fc plugin Feb 19, 2019
@texodus
Copy link
Member

texodus commented Feb 26, 2019

This is exceptionally awesome! We have discussed this offline and agreed to go ahead and merge and publish this plugin as it is already in very useful state - and we're extremely excited about the future of utilizing this plugin as the default for charting in Perspective!

For what was clearly a monumental development effort - special thanks @redbearsam @matt-hooper @DevAndyLee @Ro4052 @jacoburton104 for making it happen!

@texodus texodus merged commit d0bfe8e into finos:master Feb 26, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Feature requests or improvements JS
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants