Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Current »

To add accessibility text for charts, adding following code snippet in the JS listener for the workspace that contain the chart widgets:

CWEH.registerHandler('<Chart Widget Id>', CFEC.WIDGET_RENDERED, function() 
  {
    FusionCharts.Accessibility.setAlternateTexts(
    {
      '<Chart ID>': 
      {
        'chart': 'This is a {chartType} chart with static colors',
        'plot': 'On date {label}, the revenue is {value}.'
      }
    });
  }
//here, Chart ID = <VIEW_ID>_<WIDGET_ID>_CHART
//Chart Widget Id / Widget ID = Chart app ID

The default accessibility texts for the single-series and multi-series charts, and gauges is shown in the following code snippet:

//Single-series charts
 {
    'chart': 'This is a {chartType} chart showing {xAxisName} and {yAxisName}. ',
    'plot': '{label} value is {value}. Plot {plotIndex} of {totalPlots}.'
}

//Multi-series charts
{
    'chart': 'This is a {chartType} chart. {xAxisName} is plotted on x axis and {yAxisName} is plotted on y axis.',
    'plot': '{seriesName} for the {label} is {value}. Plot {plotIndex} of {totalPlots}. Series {seriesIndex} of {totalSeries}.'
}

//Gauges
{
    'chart': 'This is a {chartType} chart showing {xAxisName} and {yAxisName}',
    'plot': '{label} value is {value}. Plot {plotIndex} of {totalPlots}.'
}

  • No labels