Skip to content

Commit 92abd98

Browse files
committed
up
1 parent 8e9fdea commit 92abd98

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

49 files changed

+6244
-0
lines changed
Lines changed: 65 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
1+
{
2+
"$schema": "./node_modules/@angular/cli/lib/config/schema.json",
3+
"cli": {
4+
"analytics": "1e1de97b-a744-405a-8b5a-0397bb3d01ce"
5+
},
6+
"newProjectRoot": "projects",
7+
"projects": {
8+
"demo": {
9+
"architect": {
10+
"build": {
11+
"builder": "@angular-devkit/build-angular:application",
12+
"configurations": {
13+
"development": {
14+
"extractLicenses": false,
15+
"namedChunks": true,
16+
"optimization": false,
17+
"sourceMap": true
18+
},
19+
"production": {
20+
"aot": true,
21+
"extractLicenses": true,
22+
"namedChunks": false,
23+
"optimization": true,
24+
"outputHashing": "all",
25+
"sourceMap": false
26+
}
27+
},
28+
"options": {
29+
"assets": [],
30+
"index": "src/index.html",
31+
"browser": "src/main.ts",
32+
"outputPath": "dist/demo",
33+
"polyfills": ["zone.js"],
34+
"scripts": [],
35+
"styles": [
36+
"./node_modules/jqwidgets-ng/jqwidgets/styles/jqx.base.css",
37+
"./node_modules/jqwidgets-ng/jqwidgets/styles/jqx.fluent.css",
38+
"src/assets/fonts.css",
39+
"src/assets/styles.css"
40+
],
41+
"tsConfig": "src/tsconfig.app.json"
42+
}
43+
},
44+
"serve": {
45+
"builder": "@angular-devkit/build-angular:dev-server",
46+
"configurations": {
47+
"development": {
48+
"buildTarget": "demo:build:development"
49+
},
50+
"production": {
51+
"buildTarget": "demo:build:production"
52+
}
53+
},
54+
"defaultConfiguration": "development"
55+
}
56+
},
57+
"prefix": "app",
58+
"projectType": "application",
59+
"root": "",
60+
"schematics": {},
61+
"sourceRoot": "src"
62+
}
63+
},
64+
"version": 1
65+
}
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
{
2+
"name": "angular-template",
3+
"scripts": {
4+
"ng": "ng",
5+
"start": "ng serve",
6+
"build": "ng build"
7+
},
8+
"dependencies": {
9+
"@angular/animations": "^19.0.0",
10+
"@angular/common": "^19.0.0",
11+
"@angular/compiler": "^19.0.0",
12+
"@angular/core": "^19.0.0",
13+
"@angular/forms": "^19.0.0",
14+
"@angular/platform-browser": "^19.0.0",
15+
"@angular/platform-browser-dynamic": "^19.0.0",
16+
"@angular/router": "^19.0.0",
17+
"jqwidgets-ng": "^21.0.5",
18+
"rxjs": "^7.8.1",
19+
"tslib": "^2.5.0",
20+
"zone.js": "~0.15.0"
21+
},
22+
"devDependencies": {
23+
"@angular-devkit/build-angular": "^19.0.0",
24+
"@angular/cli": "^19.0.0",
25+
"@angular/compiler-cli": "^19.0.0",
26+
"typescript": "~5.5.0"
27+
}
28+
}

chart/defaultfunctionality/src/app/app.component.css

Whitespace-only changes.
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
<jqxChart #myChart
2+
[width]="getWidth()" [height]="500"
3+
[title]="'U.S. Stock Market Index Performance'"
4+
[description]="'NASDAQ Composite compared to S&P 500'"
5+
[showLegend]="true" [enableAnimations]="true" [padding]="padding"
6+
[titlePadding]="titlePadding" [source]="dataAdapter" [xAxis]="xAxis"
7+
[valueAxis]="valueAxis" [seriesGroups]="seriesGroups" [colorScheme]="'scheme04'">
8+
</jqxChart>
Lines changed: 85 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,85 @@
1+
import { Component } from '@angular/core';
2+
3+
import { jqxChartModule, jqxChartComponent } from 'jqwidgets-ng/jqxchart';
4+
@Component({
5+
selector: 'app-root',
6+
imports: [jqxChartModule],
7+
standalone: true,
8+
templateUrl: './app.component.html'
9+
})
10+
11+
export class AppComponent {
12+
months: string[] = ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'];
13+
14+
source: any =
15+
{
16+
datatype: "csv",
17+
datafields: [
18+
{ name: 'Date' },
19+
{ name: 'S&P 500' },
20+
{ name: 'NASDAQ' }
21+
],
22+
url: '../assets/nasdaq_vs_sp500.txt'
23+
};
24+
25+
dataAdapter: any = new jqx.dataAdapter(this.source, { async: false, autoBind: true, loadError: (xhr: any, status: any, error: any) => { alert('Error loading "' + this.source.url + '" : ' + error); } });
26+
27+
padding: any = { left: 10, top: 5, right: 10, bottom: 5 };
28+
29+
titlePadding: any = { left: 50, top: 0, right: 0, bottom: 10 };
30+
31+
getWidth(): any {
32+
if (document.body.offsetWidth < 850) {
33+
return '90%';
34+
}
35+
36+
return 850;
37+
}
38+
39+
xAxis: any =
40+
{
41+
dataField: 'Date',
42+
formatFunction: (value: any) => {
43+
return value.getDate() + '-' + this.months[value.getMonth()] + '-' + value.getFullYear();
44+
},
45+
type: 'date',
46+
baseUnit: 'month',
47+
valuesOnTicks: true,
48+
minValue: '01-01-2014',
49+
maxValue: '01-01-2015',
50+
tickMarks: {
51+
visible: true,
52+
interval: 1,
53+
color: '#BCBCBC'
54+
},
55+
unitInterval: 1,
56+
gridLines: {
57+
visible: true,
58+
interval: 3,
59+
color: '#BCBCBC'
60+
},
61+
labels: {
62+
angle: -45,
63+
rotationPoint: 'topright',
64+
offset: { x: 0, y: -25 }
65+
}
66+
};
67+
68+
valueAxis: any =
69+
{
70+
visible: true,
71+
title: { text: 'Daily Closing Price<br>' },
72+
tickMarks: { color: '#BCBCBC' }
73+
};
74+
75+
seriesGroups: any =
76+
[
77+
{
78+
type: 'line',
79+
series: [
80+
{ dataField: 'S&P 500', displayText: 'S&P 500' },
81+
{ dataField: 'NASDAQ', displayText: 'NASDAQ' }
82+
]
83+
}
84+
];
85+
}
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
import { NgModule } from '@angular/core';
2+
import { BrowserModule } from '@angular/platform-browser';
3+
import { FormsModule } from '@angular/forms';
4+
5+
import { AppComponent } from './app.component';
6+
7+
8+
@NgModule({
9+
declarations: [AppComponent, jqxChartComponent],
10+
imports: [BrowserModule, FormsModule],
11+
providers: [],
12+
bootstrap: [AppComponent]
13+
})
14+
15+
export class AppModule { }
16+

0 commit comments

Comments
 (0)