|
| 1 | +import { Component } from '@angular/core'; |
| 2 | +import { RouterOutlet } from '@angular/router'; |
| 3 | +import { HeatMapModule, TooltipService } from '@syncfusion/ej2-angular-heatmap'; |
| 4 | + |
| 5 | +@Component({ |
| 6 | + selector: 'app-root', |
| 7 | + standalone: true, |
| 8 | + imports: [RouterOutlet, HeatMapModule], |
| 9 | + providers: [TooltipService], |
| 10 | + templateUrl: './app.component.html', |
| 11 | + styleUrl: './app.component.css' |
| 12 | +}) |
| 13 | +export class AppComponent { |
| 14 | + public cellSettings: Object = { |
| 15 | + format: '${value}' |
| 16 | + }; |
| 17 | + public paletteSettings: Object = { |
| 18 | + palette: [ |
| 19 | + { color: '#C06C84' }, |
| 20 | + { color: '#6C5B7B' }, |
| 21 | + { color: '#355C7D' } |
| 22 | + ], |
| 23 | + type: 'Fixed' |
| 24 | + }; |
| 25 | + public xAxis: Object = { |
| 26 | + labels: ['Nancy', 'Andrew', 'Janet', 'Margaret', 'Steven', 'Michael', 'Robert', |
| 27 | + 'Laura', 'Anne', 'Paul', 'Karin', 'Mario'] |
| 28 | + }; |
| 29 | + public yAxis: Object = { |
| 30 | + labels: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat'] |
| 31 | + }; |
| 32 | + public titleSettings: Object = { |
| 33 | + text: 'Sales Revenue per Employee (in $1000 USD)' |
| 34 | + }; |
| 35 | + public heatMapData: Object[] = [ |
| 36 | + [73, 39, 26, null, 94, 0], |
| 37 | + [93, 58, 53, 38, 26, 68], |
| 38 | + [99, 28, null, 4, 66, 90], |
| 39 | + [14, 26, 97, 69, 69, 3], |
| 40 | + [7, null, 47, 47, 88, 6], |
| 41 | + [41, 55, 73, 23, 3, 79], |
| 42 | + [56, 69, 21, 86, 3, 33], |
| 43 | + [45, 7, 53, null, 95, 79], |
| 44 | + [60, 77, 74, 68, 88, 51], |
| 45 | + [25, 25, null, 12, 78, 14], |
| 46 | + [25, 56, 55, 58, 12, 82], |
| 47 | + [74, 33, null, 23, 86, 59] |
| 48 | + ]; |
| 49 | + title = 'myangularapp'; |
| 50 | +} |
0 commit comments