@coreui/angular-chartjs 4.2.15 → 4.2.35

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/LICENSE CHANGED
@@ -1,21 +1,21 @@
1
- MIT License
2
-
3
- Copyright (c) 2022 creativeLabs Łukasz Holeczek
4
-
5
- Permission is hereby granted, free of charge, to any person obtaining a copy
6
- of this software and associated documentation files (the "Software"), to deal
7
- in the Software without restriction, including without limitation the rights
8
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
- copies of the Software, and to permit persons to whom the Software is
10
- furnished to do so, subject to the following conditions:
11
-
12
- The above copyright notice and this permission notice shall be included in all
13
- copies or substantial portions of the Software.
14
-
15
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
- SOFTWARE.
1
+ MIT License
2
+
3
+ Copyright (c) 2022 creativeLabs Łukasz Holeczek
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md CHANGED
@@ -1,174 +1,174 @@
1
- <p align="center">
2
- <a href="https://coreui.io/">
3
- <img
4
- src="https://coreui.io/images/brand/coreui-signet.svg"
5
- alt="CoreUI logo"
6
- width="200"
7
- />
8
- </a>
9
- </p>
10
-
11
- <h3 align="center">CoreUI Angular wrapper for Chart.js</h3>
12
-
13
- <p align="center">
14
- <a href="https://coreui.io/angular/docs/"><strong>Explore @coreui/angular-chartjs docs & examples »</strong></a>
15
- <br>
16
- <br>
17
- <a href="https://github.com/coreui/coreui-angular/issues/new?template=bug_report.md">Report bug</a>
18
- ·
19
- <a href="https://github.com/coreui/coreui-angular/issues/new?template=feature_request.md">Request feature</a>
20
- ·
21
- <a href="https://blog.coreui.io/">Blog</a>
22
- </p>
23
-
24
- ## Status
25
-
26
- ![angular][angular-badge]
27
- [![npm package][npm-badge]][npm]
28
- [![npm package][npm-badge-next]][npm]
29
- [![NPM downloads][npm-download]][npm]
30
-
31
-
32
- [npm-badge]: https://img.shields.io/npm/v/@coreui/angular-chartjs/latest?style=flat-square&color=brightgreen
33
- [npm-badge-next]: https://img.shields.io/npm/v/@coreui/angular-chartjs/next?style=flat-square&color=red
34
- [npm]: https://www.npmjs.com/package/@coreui/angular-chartjs
35
- [npm-download]: https://img.shields.io/npm/dm/@coreui/angular-chartjs.svg?style=flat-square
36
- [angular-badge]: https://img.shields.io/badge/angular-^14.0.0-lightgrey.svg?style=flat-square&logo=angular
37
-
38
- ##### install:
39
-
40
- ```bash
41
- npm install chart.js
42
- npm install @coreui/chartjs@3
43
- npm install @coreui/angular-chartjs
44
- ````
45
-
46
- ##### import:
47
-
48
- ```ts
49
- import { ChartjsModule } from '@coreui/angular-chartjs';
50
-
51
- @NgModule({
52
- imports: [
53
- ChartjsModule,
54
- ...
55
- ```
56
-
57
- ##### usage:
58
-
59
- ```tsx
60
- @Component({
61
- selector: 'app-chart-sample',
62
- template: `<c-chart type="line" [data]="data" [options]="options" width="300"></c-chart>`,
63
- })
64
- export class ChartSample {
65
-
66
- colors = {
67
- label: 'My dataset',
68
- backgroundColor: 'rgba(77,189,116,.2)',
69
- borderColor: '#4dbd74',
70
- pointHoverBackgroundColor: '#fff',
71
- }
72
-
73
- labels = ['Mo', 'Tu', 'We', 'Th', 'Fr', 'Sa', 'Su'];
74
-
75
- data = {
76
- labels: this.labels,
77
- datasets: [{
78
- data: [65, 59, 84, 84, 51, 55, 40],
79
- ...this.colors,
80
- fill: {value: 65}
81
- }],
82
- }
83
-
84
- options = {
85
- plugins: {
86
- legend: {
87
- display: false
88
- }
89
- },
90
- maintainAspectRatio: false,
91
- elements: {
92
- line: {
93
- tension: 0.4
94
- },
95
- }
96
- };
97
- }
98
- ```
99
- ![README.png](./README.png)
100
-
101
-
102
- ### c-chart
103
- _component_
104
-
105
- ##### Inputs:
106
-
107
- |name|description|type|default|
108
- |---|---|---|---|
109
- |`customTooltips`|Enables custom html based tooltips|`boolean`|_true_
110
- |`data`|The data passed to Chart.js chart|[`ChartData`](https://www.chartjs.org/docs/latest/api/interfaces/ChartData.html)|**required**
111
- |`options`|The options object that is passed into the Chart.js chart|[`ChartOptions`](https://www.chartjs.org/docs/latest/general/options.html)|_undefined_
112
- |`plugins`|The plugins array that is passed into the Chart.js chart|[`PluginOptionsByType`](https://www.chartjs.org/docs/latest/api/interfaces/PluginOptionsByType.html)|_undefined_
113
- |`redraw`|If true, will tear down and redraw chart on all updates|`boolean`|_false_
114
- |`type`|Chart.js chart type.|[`keyof ChartTypeRegistry`](https://www.chartjs.org/docs/latest/api/interfaces/ChartTypeRegistry.html)|_bar_
115
- |`wrapper`|Put the chart into the wrapper with `display: block`.|`boolean`|_true_
116
- |`height`|Height attribute applied to the rendered canvas (px)|`number`|_undefined_
117
- |`width`|Width attribute applied to the rendered canvas (px)|`number`|_undefined_
118
- |`id`|Html id attribute applied to the rendered canvas|`string`|_undefined_
119
-
120
- ##### Outputs:
121
-
122
- |name|description|
123
- |---|---|
124
- |`getDatasetAtEvent`|Proxy for Chart.js getDatasetAtEvent. Calls with dataset and triggering event.
125
- |`getElementAtEvent`|Proxy for Chart.js getElementAtEvent. Calls with single element array and triggering event.
126
- |`getElementsAtEvent`|Proxy for Chart.js getElementsAtEvent. Calls with element array and triggering event.
127
-
128
-
129
- ### See also:
130
-
131
- - Chart.js docs [https://www.chartjs.org/docs/](https://www.chartjs.org/docs/)
132
-
133
- <!--- StartOpenCollectiveBackers -->
134
-
135
- ## Support CoreUI Development
136
-
137
- CoreUI is an MIT-licensed open source project and is completely free to use. However, the amount of effort needed to maintain and develop new features for the project is not sustainable without proper financial backing. You can support development by buying the [CoreUI PRO](https://coreui.io/pricing/) or by becoming a sponsor via [Open Collective](https://opencollective.com/coreui/).
138
-
139
-
140
- ### Platinum Sponsors
141
-
142
- Support this project by [becoming a Platinum Sponsor](https://opencollective.com/coreui/contribute/platinum-sponsor-40959/). A large company logo will be added here with a link to your website.
143
-
144
- <a href="https://opencollective.com/coreui/contribute/platinum-sponsor-40959/checkout"><img src="https://opencollective.com/coreui/tiers/platinum-sponsor/0/avatar.svg?avatarHeight=100"></a>
145
-
146
- ### Gold Sponsors
147
-
148
- Support this project by [becoming a Gold Sponsor](https://opencollective.com/coreui/contribute/gold-sponsor-40960/). A big company logo will be added here with a link to your website.
149
-
150
- <a href="https://opencollective.com/coreui/contribute/gold-sponsor-40960/checkout"><img src="https://opencollective.com/coreui/tiers/gold-sponsor/0/avatar.svg?avatarHeight=100"></a>
151
-
152
- ### Silver Sponsors
153
-
154
- Support this project by [becoming a Silver Sponsor](https://opencollective.com/coreui/contribute/silver-sponsor-40967/). A medium company logo will be added here with a link to your website.
155
-
156
- <a href="https://opencollective.com/coreui/contribute/silver-sponsor-40967/checkout"><img src="https://opencollective.com/coreui/tiers/gold-sponsor/0/avatar.svg?avatarHeight=100"></a>
157
-
158
- ### Bronze Sponsors
159
-
160
- Support this project by [becoming a Bronze Sponsor](https://opencollective.com/coreui/contribute/bronze-sponsor-40966/). The company avatar will show up here with a link to your OpenCollective Profile.
161
-
162
- <a href="https://opencollective.com/coreui/contribute/bronze-sponsor-40966/checkout"><img src="https://opencollective.com/coreui/tiers/bronze-sponsor/0/avatar.svg?avatarHeight=100"></a>
163
-
164
- ### Backers
165
-
166
- Thanks to all the backers and sponsors! Support this project by [becoming a backer](https://opencollective.com/coreui/contribute/backer-40965/).
167
-
168
- <a href="https://opencollective.com/coreui/contribute/backer-40965/checkout" target="_blank" rel="noopener"><img src="https://opencollective.com/coreui/backers.svg?width=890"></a>
169
-
170
- <!--- EndOpenCollectiveBackers -->
171
-
172
- ## Copyright and license
173
-
174
- Copyright 2022 creativeLabs Łukasz Holeczek. Code released under the [MIT License](https://github.com/coreui/coreui-angular/blob/main/LICENSE). Docs released under [Creative Commons](https://creativecommons.org/licenses/by/3.0/).
1
+ <p align="center">
2
+ <a href="https://coreui.io/">
3
+ <img
4
+ src="https://coreui.io/images/brand/coreui-signet.svg"
5
+ alt="CoreUI logo"
6
+ width="200"
7
+ />
8
+ </a>
9
+ </p>
10
+
11
+ <h3 align="center">CoreUI Angular wrapper for Chart.js</h3>
12
+
13
+ <p align="center">
14
+ <a href="https://coreui.io/angular/docs/"><strong>Explore @coreui/angular-chartjs docs & examples »</strong></a>
15
+ <br>
16
+ <br>
17
+ <a href="https://github.com/coreui/coreui-angular/issues/new?template=bug_report.md">Report bug</a>
18
+ ·
19
+ <a href="https://github.com/coreui/coreui-angular/issues/new?template=feature_request.md">Request feature</a>
20
+ ·
21
+ <a href="https://blog.coreui.io/">Blog</a>
22
+ </p>
23
+
24
+ ## Status
25
+
26
+ ![angular][angular-badge]
27
+ [![npm package][npm-badge]][npm]
28
+ [![npm package][npm-badge-next]][npm]
29
+ [![NPM downloads][npm-download]][npm]
30
+
31
+
32
+ [npm-badge]: https://img.shields.io/npm/v/@coreui/angular-chartjs/latest?style=flat-square&color=brightgreen
33
+ [npm-badge-next]: https://img.shields.io/npm/v/@coreui/angular-chartjs/next?style=flat-square&color=red
34
+ [npm]: https://www.npmjs.com/package/@coreui/angular-chartjs
35
+ [npm-download]: https://img.shields.io/npm/dm/@coreui/angular-chartjs.svg?style=flat-square
36
+ [angular-badge]: https://img.shields.io/badge/angular-^14.0.0-lightgrey.svg?style=flat-square&logo=angular
37
+
38
+ ##### install:
39
+
40
+ ```bash
41
+ npm install chart.js
42
+ npm install @coreui/chartjs@3
43
+ npm install @coreui/angular-chartjs
44
+ ````
45
+
46
+ ##### import:
47
+
48
+ ```ts
49
+ import { ChartjsModule } from '@coreui/angular-chartjs';
50
+
51
+ @NgModule({
52
+ imports: [
53
+ ChartjsModule,
54
+ ...
55
+ ```
56
+
57
+ ##### usage:
58
+
59
+ ```tsx
60
+ @Component({
61
+ selector: 'app-chart-sample',
62
+ template: `<c-chart type="line" [data]="data" [options]="options" width="300"></c-chart>`,
63
+ })
64
+ export class ChartSample {
65
+
66
+ colors = {
67
+ label: 'My dataset',
68
+ backgroundColor: 'rgba(77,189,116,.2)',
69
+ borderColor: '#4dbd74',
70
+ pointHoverBackgroundColor: '#fff',
71
+ }
72
+
73
+ labels = ['Mo', 'Tu', 'We', 'Th', 'Fr', 'Sa', 'Su'];
74
+
75
+ data = {
76
+ labels: this.labels,
77
+ datasets: [{
78
+ data: [65, 59, 84, 84, 51, 55, 40],
79
+ ...this.colors,
80
+ fill: {value: 65}
81
+ }],
82
+ }
83
+
84
+ options = {
85
+ plugins: {
86
+ legend: {
87
+ display: false
88
+ }
89
+ },
90
+ maintainAspectRatio: false,
91
+ elements: {
92
+ line: {
93
+ tension: 0.4
94
+ },
95
+ }
96
+ };
97
+ }
98
+ ```
99
+ ![README.png](./README.png)
100
+
101
+
102
+ ### c-chart
103
+ _component_
104
+
105
+ ##### Inputs:
106
+
107
+ |name|description|type|default|
108
+ |---|---|---|---|
109
+ |`customTooltips`|Enables custom html based tooltips|`boolean`|_true_
110
+ |`data`|The data passed to Chart.js chart|[`ChartData`](https://www.chartjs.org/docs/latest/api/interfaces/ChartData.html)|**required**
111
+ |`options`|The options object that is passed into the Chart.js chart|[`ChartOptions`](https://www.chartjs.org/docs/latest/general/options.html)|_undefined_
112
+ |`plugins`|The plugins array that is passed into the Chart.js chart|[`PluginOptionsByType`](https://www.chartjs.org/docs/latest/api/interfaces/PluginOptionsByType.html)|_undefined_
113
+ |`redraw`|If true, will tear down and redraw chart on all updates|`boolean`|_false_
114
+ |`type`|Chart.js chart type.|[`keyof ChartTypeRegistry`](https://www.chartjs.org/docs/latest/api/interfaces/ChartTypeRegistry.html)|_bar_
115
+ |`wrapper`|Put the chart into the wrapper with `display: block`.|`boolean`|_true_
116
+ |`height`|Height attribute applied to the rendered canvas (px)|`number`|_undefined_
117
+ |`width`|Width attribute applied to the rendered canvas (px)|`number`|_undefined_
118
+ |`id`|Html id attribute applied to the rendered canvas|`string`|_undefined_
119
+
120
+ ##### Outputs:
121
+
122
+ |name|description|
123
+ |---|---|
124
+ |`getDatasetAtEvent`|Proxy for Chart.js getDatasetAtEvent. Calls with dataset and triggering event.
125
+ |`getElementAtEvent`|Proxy for Chart.js getElementAtEvent. Calls with single element array and triggering event.
126
+ |`getElementsAtEvent`|Proxy for Chart.js getElementsAtEvent. Calls with element array and triggering event.
127
+
128
+
129
+ ### See also:
130
+
131
+ - Chart.js docs [https://www.chartjs.org/docs/](https://www.chartjs.org/docs/)
132
+
133
+ <!--- StartOpenCollectiveBackers -->
134
+
135
+ ## Support CoreUI Development
136
+
137
+ CoreUI is an MIT-licensed open source project and is completely free to use. However, the amount of effort needed to maintain and develop new features for the project is not sustainable without proper financial backing. You can support development by buying the [CoreUI PRO](https://coreui.io/pricing/) or by becoming a sponsor via [Open Collective](https://opencollective.com/coreui/).
138
+
139
+
140
+ ### Platinum Sponsors
141
+
142
+ Support this project by [becoming a Platinum Sponsor](https://opencollective.com/coreui/contribute/platinum-sponsor-40959/). A large company logo will be added here with a link to your website.
143
+
144
+ <a href="https://opencollective.com/coreui/contribute/platinum-sponsor-40959/checkout"><img src="https://opencollective.com/coreui/tiers/platinum-sponsor/0/avatar.svg?avatarHeight=100"></a>
145
+
146
+ ### Gold Sponsors
147
+
148
+ Support this project by [becoming a Gold Sponsor](https://opencollective.com/coreui/contribute/gold-sponsor-40960/). A big company logo will be added here with a link to your website.
149
+
150
+ <a href="https://opencollective.com/coreui/contribute/gold-sponsor-40960/checkout"><img src="https://opencollective.com/coreui/tiers/gold-sponsor/0/avatar.svg?avatarHeight=100"></a>
151
+
152
+ ### Silver Sponsors
153
+
154
+ Support this project by [becoming a Silver Sponsor](https://opencollective.com/coreui/contribute/silver-sponsor-40967/). A medium company logo will be added here with a link to your website.
155
+
156
+ <a href="https://opencollective.com/coreui/contribute/silver-sponsor-40967/checkout"><img src="https://opencollective.com/coreui/tiers/gold-sponsor/0/avatar.svg?avatarHeight=100"></a>
157
+
158
+ ### Bronze Sponsors
159
+
160
+ Support this project by [becoming a Bronze Sponsor](https://opencollective.com/coreui/contribute/bronze-sponsor-40966/). The company avatar will show up here with a link to your OpenCollective Profile.
161
+
162
+ <a href="https://opencollective.com/coreui/contribute/bronze-sponsor-40966/checkout"><img src="https://opencollective.com/coreui/tiers/bronze-sponsor/0/avatar.svg?avatarHeight=100"></a>
163
+
164
+ ### Backers
165
+
166
+ Thanks to all the backers and sponsors! Support this project by [becoming a backer](https://opencollective.com/coreui/contribute/backer-40965/).
167
+
168
+ <a href="https://opencollective.com/coreui/contribute/backer-40965/checkout" target="_blank" rel="noopener"><img src="https://opencollective.com/coreui/backers.svg?width=890"></a>
169
+
170
+ <!--- EndOpenCollectiveBackers -->
171
+
172
+ ## Copyright and license
173
+
174
+ Copyright 2022 creativeLabs Łukasz Holeczek. Code released under the [MIT License](https://github.com/coreui/coreui-angular/blob/main/LICENSE). Docs released under [Creative Commons](https://creativecommons.org/licenses/by/3.0/).
@@ -1,5 +1,5 @@
1
- /**
2
- * Generated bundle index. Do not edit.
3
- */
4
- export * from './public-api';
1
+ /**
2
+ * Generated bundle index. Do not edit.
3
+ */
4
+ export * from './public-api';
5
5
  //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY29yZXVpLWFuZ3VsYXItY2hhcnRqcy5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uL3Byb2plY3RzL2NvcmV1aS1hbmd1bGFyLWNoYXJ0anMvc3JjL2NvcmV1aS1hbmd1bGFyLWNoYXJ0anMudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUE7O0dBRUc7QUFFSCxjQUFjLGNBQWMsQ0FBQyIsInNvdXJjZXNDb250ZW50IjpbIi8qKlxuICogR2VuZXJhdGVkIGJ1bmRsZSBpbmRleC4gRG8gbm90IGVkaXQuXG4gKi9cblxuZXhwb3J0ICogZnJvbSAnLi9wdWJsaWMtYXBpJztcbiJdfQ==