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(core): create heatmap chart #1200

Merged
merged 74 commits into from
Dec 24, 2021
Merged
Show file tree
Hide file tree
Changes from 72 commits
Commits
Show all changes
74 commits
Select commit Hold shift + click to select a range
c00affc
Create custom heatmap model
Akshat55 Oct 25, 2021
7ce44e4
Create heatmap interface
Akshat55 Oct 25, 2021
e473704
Create new color legend
Akshat55 Oct 25, 2021
42b0ef4
Create heatmap component
Akshat55 Oct 25, 2021
1f8bb9a
Setup heatmap configs
Akshat55 Oct 25, 2021
90b6aa3
Export heatmap component
Akshat55 Oct 25, 2021
3480b3f
Export heatmap data
Akshat55 Oct 25, 2021
f30d922
Update cartesian model inheritance
Akshat55 Oct 25, 2021
58f02a7
Update axis chart to use color scale legend if heatmap (temp)
Akshat55 Oct 25, 2021
f79640b
Enable heatmap in angular
Akshat55 Oct 25, 2021
559639a
Enable heatmap in react
Akshat55 Oct 25, 2021
7407ca0
Enable heatmap in vue
Akshat55 Oct 25, 2021
9f6893c
Enable heatmap in svelte
Akshat55 Oct 25, 2021
48add4d
Merge branch 'master' of https://github.com/carbon-design-system/carb…
Akshat55 Oct 25, 2021
5e94859
Reposition tooltip on axes hover
Akshat55 Oct 26, 2021
7e49630
Remove time axes demo
Akshat55 Oct 26, 2021
7e59814
Remove hardcoded styles on hover
Akshat55 Oct 27, 2021
2a631bd
Create heatmap styles
Akshat55 Oct 27, 2021
251e694
Format files
Akshat55 Oct 27, 2021
fde42f2
enable multiple color legend options
Akshat55 Nov 9, 2021
3a9d14d
Add check for scaleTypes that are not labels
Akshat55 Nov 9, 2021
ec4bf89
Improve get unique values performance conditionally
Akshat55 Nov 9, 2021
cd855a3
Add axis hover rectangles to add a single drop-shadow
Akshat55 Nov 9, 2021
02addcf
Update demos
Akshat55 Nov 9, 2021
1da437a
revert
Akshat55 Nov 10, 2021
780ed75
Add custom components list in model
Akshat55 Nov 10, 2021
53093da
Remove console message
Akshat55 Nov 10, 2021
285e59e
Add custom color legend config to legend options
Akshat55 Nov 10, 2021
4e5e2f2
Set a fixed legend height
Akshat55 Nov 10, 2021
41ef3ee
Export color legend styles
Akshat55 Nov 10, 2021
314b715
Adjust stroke width on different divider states
Akshat55 Nov 11, 2021
99a43bf
Add gradient color class sequence
Akshat55 Nov 14, 2021
9249a17
Update chart configs & interfaces
Akshat55 Nov 14, 2021
75c8c2d
Add color legend specific non-customizable configs
Akshat55 Nov 15, 2021
150e8cb
Model changes to support quantize scale
Akshat55 Nov 15, 2021
94e3c93
Use css classes for fill color if quantize scale is used
Akshat55 Nov 15, 2021
d6f3e13
Implement quantize legend support
Akshat55 Nov 15, 2021
935cb14
Merge branch 'master' of https://github.com/carbon-design-system/carb…
Akshat55 Nov 15, 2021
7b5c200
Merge branch 'master' of https://github.com/carbon-design-system/carb…
Akshat55 Nov 17, 2021
e4652a6
Extend axis and add tab index support to heatmap
Akshat55 Nov 22, 2021
1b0ed0e
Improve axis highlight event
Akshat55 Nov 24, 2021
fa4be7e
Improve hover accessibility
Akshat55 Nov 28, 2021
7ef4797
Dispatch correct events
Akshat55 Nov 28, 2021
1fed27e
Add gradient colors to css
Akshat55 Nov 29, 2021
4ca4300
Add axis render event and missing focus and blur
Akshat55 Nov 29, 2021
de64f46
Remove linear gradient from model
Akshat55 Nov 29, 2021
e2ee256
Make color scale legend more independent from class model
Akshat55 Nov 29, 2021
22c7186
Add divider off demo to axis heatmap demo
Akshat55 Nov 29, 2021
9fbbe3e
Update spacing between axis & legend
Akshat55 Nov 29, 2021
ba2cd29
Adjust legend position after axis loads
Akshat55 Nov 29, 2021
741052b
hover bug fixes
Akshat55 Nov 29, 2021
7e1bfcc
format
Akshat55 Nov 29, 2021
8f051d1
Merge branch 'master' of https://github.com/carbon-design-system/carb…
Akshat55 Nov 29, 2021
4296143
Move row and column highlighting outside of chart
Akshat55 Nov 30, 2021
25ccd15
format
Akshat55 Nov 30, 2021
ea6dbe4
Align legend title with axis
Akshat55 Nov 30, 2021
f86e7ce
Improve shadow and highlighting in cell, column and row
Akshat55 Dec 1, 2021
9e04fd5
Remove divider demo
Akshat55 Dec 2, 2021
89006fb
fix axis truncation hover
Akshat55 Dec 3, 2021
a95cf8f
Fix bounding cell lines & highlighter issues
Akshat55 Dec 5, 2021
85692e4
Merge branch 'master' into heatmap
Akshat55 Dec 6, 2021
053c9e9
Merge branch 'master' of https://github.com/carbon-design-system/carb…
Akshat55 Dec 8, 2021
00ce1a9
Move heatmap demos to complex charts
Akshat55 Dec 8, 2021
734e6eb
Add padding to hover rectangles & fix event dispatch issue
Akshat55 Dec 8, 2021
ee3c38a
Make color scale rect width responsive based on option width
Akshat55 Dec 8, 2021
6444654
Implement the requested pattern demo
Akshat55 Dec 8, 2021
b57e14c
Add rendertype to color legend in heatmap
Akshat55 Dec 8, 2021
4ba305b
Fix requested changes
Akshat55 Dec 21, 2021
d846b12
Correct model variable spelling
Akshat55 Dec 21, 2021
a74cbf4
Performance improvements & enum updates
Akshat55 Dec 23, 2021
07d6636
Update packages/core/src/components/axes/hover-axis.ts
theiliad Dec 23, 2021
f6c8a45
Update packages/core/src/components/axes/hover-axis.ts
theiliad Dec 23, 2021
8fb5e82
Remove color legend options from legend options
Akshat55 Dec 24, 2021
1d85797
Make heatmap experimental
Akshat55 Dec 24, 2021
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions packages/angular/src/charts.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ import { TreeChartComponent } from './tree-chart.component';
import { TreemapChartComponent } from './treemap-chart.component';
import { CirclePackChartComponent } from './circle-pack-chart.component';
import { WordCloudChartComponent } from './wordcloud-chart.component';
import { HeatmapChartComponent } from './heatmap-chart.component';

@NgModule({
imports: [CommonModule],
Expand All @@ -41,6 +42,7 @@ import { WordCloudChartComponent } from './wordcloud-chart.component';
BulletChartComponent,
DonutChartComponent,
GaugeChartComponent,
HeatmapChartComponent,
HistogramChartComponent,
LineChartComponent,
LollipopChartComponent,
Expand All @@ -67,6 +69,7 @@ import { WordCloudChartComponent } from './wordcloud-chart.component';
BulletChartComponent,
DonutChartComponent,
GaugeChartComponent,
HeatmapChartComponent,
HistogramChartComponent,
LineChartComponent,
LollipopChartComponent,
Expand Down
34 changes: 34 additions & 0 deletions packages/angular/src/heatmap-chart.component.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
import {
Component,
AfterViewInit
} from "@angular/core";

import { BaseChart } from "./base-chart.component";

import { HeatmapChart } from "@carbon/charts";

/**
* Wrapper around `Heatmap` in carbon charts library
*
* Most functions just call their equivalent from the chart library.
*/
@Component({
selector: "ibm-heatmap-chart",
template: ``
})
export class HeatmapChartComponent extends BaseChart implements AfterViewInit {
/**
* Runs after view init to create a chart, attach it to `elementRef` and draw it.
*/
ngAfterViewInit() {
this.chart = new HeatmapChart(
this.elementRef.nativeElement,
{
data: this.data,
options: this.options
}
);

Object.assign(this, this.chart);
}
}
1 change: 1 addition & 0 deletions packages/angular/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ export * from './treemap-chart.component';
export * from './circle-pack-chart.component';
export * from './wordcloud-chart.component';
export * from './alluvial-chart.component';
export * from './heatmap-chart.component';

// Diagrams
export * from './diagrams/card-node/card-node.module';
Expand Down
5 changes: 5 additions & 0 deletions packages/core/demo/data/CHART_TYPES.ts
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,11 @@ export default {
angular: 'ibm-grouped-bar-chart',
vue: 'ccv-grouped-bar-chart',
},
HeatmapChart: {
vanilla: 'HeatmapChart',
angular: 'ibm-heatmap-chart',
vue: 'ccv-heatmap-chart',
},
HistogramChart: {
vanilla: 'HistogramChart',
angular: 'ibm-histogram-chart',
Expand Down
Loading