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

docs(core): add demo to change toolbar overflow menu control text for defined types #1296

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
5 changes: 5 additions & 0 deletions packages/core/demo/data/index.ts
Expand Up @@ -307,6 +307,11 @@ const utilityDemoGroups = [
data: toolbarDemos.toolbarLineTimeSeriesData,
chartType: chartTypes.LineChart,
},
{
options: toolbarDemos.toolbarBarSimpleOptions,
data: toolbarDemos.toolbarBarSimpleData,
chartType: chartTypes.SimpleBarChart,
},
],
},
{
Expand Down
23 changes: 23 additions & 0 deletions packages/core/demo/data/toolbar.ts
Expand Up @@ -78,3 +78,26 @@ export const toolbarLineTimeSeriesOptions = addToolbarOptions(
],
}
);

export const toolbarBarSimpleData = barChart.simpleBarData;
export const toolbarBarSimpleOptions = addToolbarOptions(
Object.assign({}, barChart.simpleBarOptions),
{
titleSuffix: ' - overriding export titles',
numberOfIcons: 1,
controls: [
{
type: 'Export as CSV',
text: 'Export data as CSV',
},
{
type: 'Export as JPG',
text: 'Export chart in JPG',
},
{
type: 'Export as PNG',
text: 'Export chart in PNG',
},
],
}
);