@carbon/charts 0.53.3 → 0.53.4
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/CHANGELOG.md +11 -0
- package/build/src/components/axes/toolbar.d.ts +5 -1
- package/build/src/interfaces/components.d.ts +19 -0
- package/build/src/interfaces/enums.d.ts +2 -1
- package/build/src/interfaces/events.d.ts +2 -1
- package/bundle.js +1 -1
- package/components/axes/toolbar.d.ts +5 -1
- package/components/axes/toolbar.js +94 -34
- package/components/axes/toolbar.js.map +1 -1
- package/demo/data/bundle.js +1 -1
- package/demo/data/toolbar.js +12 -0
- package/demo/data/toolbar.js.map +1 -1
- package/demo/tsconfig.tsbuildinfo +1 -1
- package/interfaces/components.d.ts +19 -0
- package/interfaces/components.js.map +1 -1
- package/interfaces/enums.d.ts +2 -1
- package/interfaces/enums.js +1 -0
- package/interfaces/enums.js.map +1 -1
- package/interfaces/events.d.ts +2 -1
- package/interfaces/events.js +1 -0
- package/interfaces/events.js.map +1 -1
- package/package.json +1 -1
- package/tsconfig.tsbuildinfo +8 -8
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,17 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
## [0.53.4](https://github.com/carbon-design-system/carbon-charts/compare/v0.53.3...v0.53.4) (2021-12-13)
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
### Bug Fixes
|
|
10
|
+
|
|
11
|
+
* **core:** allow users to define custom buttons in toolbar ([#1158](https://github.com/carbon-design-system/carbon-charts/issues/1158)) ([4996591](https://github.com/carbon-design-system/carbon-charts/commit/499659155b56df9f7ab03633e43f5437f21bb129)), closes [#1129](https://github.com/carbon-design-system/carbon-charts/issues/1129)
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
|
|
6
17
|
## [0.53.3](https://github.com/carbon-design-system/carbon-charts/compare/v0.53.2...v0.53.3) (2021-12-07)
|
|
7
18
|
|
|
8
19
|
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { Component } from '../component';
|
|
2
2
|
import { RenderTypes, ToolbarControlTypes } from '../../interfaces';
|
|
3
3
|
export declare class Toolbar extends Component {
|
|
4
|
+
static buttonID: number;
|
|
4
5
|
type: string;
|
|
5
6
|
renderType: RenderTypes;
|
|
6
7
|
overflowButton: any;
|
|
@@ -15,6 +16,7 @@ export declare class Toolbar extends Component {
|
|
|
15
16
|
focusOnPreviousEnabledMenuItem(currentItemIndex: any): void;
|
|
16
17
|
focusOnNextEnabledMenuItem(currentItemIndex: any): void;
|
|
17
18
|
toggleOverflowMenu(event: any): void;
|
|
19
|
+
triggerFunctionAndEvent(control: any, event: any, element?: any): void;
|
|
18
20
|
getControlConfigs(): {
|
|
19
21
|
buttonList: any[];
|
|
20
22
|
overflowMenuItemList?: undefined;
|
|
@@ -28,7 +30,9 @@ export declare class Toolbar extends Component {
|
|
|
28
30
|
id: string;
|
|
29
31
|
title: string;
|
|
30
32
|
shouldBeDisabled: () => boolean;
|
|
31
|
-
|
|
33
|
+
iconSVG: {
|
|
34
|
+
content: string;
|
|
35
|
+
};
|
|
32
36
|
clickFunction: (event: any) => void;
|
|
33
37
|
};
|
|
34
38
|
getControlConfigByType(controlType: ToolbarControlTypes): any;
|
|
@@ -152,6 +152,25 @@ export interface ToolbarControl {
|
|
|
152
152
|
* type value will be displayed if text is not available
|
|
153
153
|
*/
|
|
154
154
|
text?: string;
|
|
155
|
+
/**
|
|
156
|
+
* custom id for button
|
|
157
|
+
*/
|
|
158
|
+
id?: String;
|
|
159
|
+
/**
|
|
160
|
+
* SVG HTML element
|
|
161
|
+
*/
|
|
162
|
+
iconSVG?: {
|
|
163
|
+
content?: string;
|
|
164
|
+
height?: string;
|
|
165
|
+
width?: string;
|
|
166
|
+
};
|
|
167
|
+
shouldBeDisabled?: Function;
|
|
168
|
+
/**
|
|
169
|
+
* function to execute on button click
|
|
170
|
+
* alternatively, users can choose to not pass in a function and can
|
|
171
|
+
* listen for events to execute asynchronously
|
|
172
|
+
*/
|
|
173
|
+
clickFunction?: Function;
|
|
155
174
|
}
|
|
156
175
|
/**
|
|
157
176
|
* customize the ZoomBars in a chart
|
|
@@ -203,7 +203,8 @@ export declare enum ToolbarControlTypes {
|
|
|
203
203
|
ZOOM_OUT = "Zoom out",
|
|
204
204
|
RESET_ZOOM = "Reset zoom",
|
|
205
205
|
MAKE_FULLSCREEN = "Make fullscreen",
|
|
206
|
-
SHOW_AS_DATATABLE = "Show as data-table"
|
|
206
|
+
SHOW_AS_DATATABLE = "Show as data-table",
|
|
207
|
+
CUSTOM = "Custom"
|
|
207
208
|
}
|
|
208
209
|
/**
|
|
209
210
|
* enum of title orientations for _vertical axes_
|
|
@@ -25,7 +25,8 @@ export declare enum Model {
|
|
|
25
25
|
*/
|
|
26
26
|
export declare enum Toolbar {
|
|
27
27
|
SHOW_OVERFLOW_MENU = "show-toolbar-overflow-menu",
|
|
28
|
-
HIDE_OVERFLOW_MENU = "hide-toolbar-overflow-menu"
|
|
28
|
+
HIDE_OVERFLOW_MENU = "hide-toolbar-overflow-menu",
|
|
29
|
+
BUTTON_CLICK = "toolbar-button-click"
|
|
29
30
|
}
|
|
30
31
|
/**
|
|
31
32
|
* enum of all events related to the zoom-bar
|