Closed dpgiakatos closed 8 months ago
Ensuring that visual elements, including line charts, comply with Web Content Accessibility Guidelines (WCAG) 2.1 is crucial for making content accessible to a wide range of users. Here are key considerations to make line charts WCAG-compliant:
Color Contrast:
Text Alternatives:
Interactive Features:
Keyboard Access:
Data Tables:
Avoid Red-Green Combinations:
Use ARIA Roles:
Provide Descriptive Titles:
By incorporating these considerations, enhance the accessibility on line charts, making them more inclusive for users with diverse abilities. Regular testing and user feedback are essential to ensure ongoing accessibility improvements.
@dpgiakatos would like to work on this issue.
As a first step, let's concentrate on one rule—Low Vision Issue Rationale. My suggestion is to integrate a button into the Plotly ModeBar (check the example here: Plotly Configuration Options). This button would open a menu, allowing users to choose from the following categories:
What are your thoughts on this approach?
The above appraoch does sound good :
but as per my research Plotly.js
still does not have a built-in dropdown component for the modebar.
So approaches can be :
Plotly Configuration Options as they use the toggler button to toggle beteween different categories . This also opens to possibility of changing the icon with each click that changes the color and icon to signify(instead of dropdown) ( icons are subject to change )
A custom dropdown : like this
No, I don't think a dropdown button is a good idea, as it may confuse the user (they might perceive it as an action button rather than a help button). Instead, let's have a button in the modebar that opens a dialog (see example: Quasar Dialog) where the user can select the categories. This solution not only addresses the current issue but also provides an opportunity to incorporate additional accessibility features for the plot in the future.
Regarding colors, have you checked if Plotly provides palettes with colors specifically designed for the four categories (None, Protanopia, Tritanopia, Achromatopsia)? I haven't searched for it yet.
As the above tasks require research and feasibility check will be updating this comment with research and breaking down the task : ) The Dialog Box approach is quite great and surely will be helpful in other accessibility features. Tasks :
I agree with this approach to the tasks, except for the third point. Let's focus solely on colors for now.
A Seperate File example PlotyChartColor.js which will contain json object with
// PlotyChartColor.js
const colorPalettes = {
"dark": [
{
"Protan": [// array of 10 colors],
"Deutan": [// array of 10 colors],
"Tritan": [// array of 10 colors]
},
{
"Protan": [// array of 10 colors],
"Deutan": [// array of 10 colors],
"Tritan": [// array of 10 colors]
},
{
"Protan": [// array of 10 colors],
"Deutan": [// array of 10 colors],
"Tritan": [// array of 10 colors]
}
],
"light": [
{
"Protan": [// array of 10 colors],
"Deutan": [// array of 10 colors],
"Tritan": [// array of 10 colors]
},
{
"Protan": [// array of 10 colors],
"Deutan": [// array of 10 colors],
"Tritan": [// array of 10 colors]
},
{
"Protan": [// array of 10 colors],
"Deutan": [// array of 10 colors],
"Tritan": [// array of 10 colors]
}
]
};
module.exports = colorPalettes;
Colors for data visualization
) section the website offers color Palettes where we can select WCAG compliant colors and Different color categories with Different background colors Dark and Light (Black and White)layoutLocal
function and add a property colorway:
which is supported by ploty.jscolorway:
and then we will watch a variable using vue watch and we will then run react() function to rerender and update the colors in the chartNetworkDelayChart.vue
and RirCountrySunburstChart.vue
these two is overiding the chart colors we have to remove the colors in these two components.@dpgiakatos @mohamedawnallah pls review it.
I think that @horizenight is working on this issue. So, @horizenight, do we have any progress?
I think that @horizenight is working on this issue. So, @horizenight, do we have any progress?
The issue was opened for a long time with no progress report. That's why
@dpgiakatos is the dark theme Looking good?
There is no rush for this issue, as it is an app enhancement. Let's wait for his reply first, and we'll proceed accordingly. Also, @ArnabBCA, please do not implement anything without being assigned first.
@dpgiakatos is the dark theme Looking good?
The dark theme should also be combined with the corresponding palettes. As mentioned, it is already an issue #684, but it is also connected to this issue. So, if @horizenight has made some progress on this issue, then you might work together on the color palettes (dark theme and Low Vision Issue Rationale). In any case, we should wait for his reply first.
Hello @dpgiakatos Thank you for waiting for my response, got really busy in college endeavours.
But here is my research finding:
An example of this approach :
This source defines the colors we can use in the pallete for each category: https://mk.bcgsc.ca/colorblind/palettes.mhtml#projecthome
For Discussion:
Nice article! Let's go with the 24-color palette. Additionally, let's add a temporary button in the footer (subject to discussion with other maintainers for potential changes later) that will open a dialog. This dialog will allow users to switch between light/dark themes and between color palettes for color blindness.
Also, @horizenight and @ArnabBCA, would you like to collaborate on addressing issues #684 and #709?
Nice article! Let's go with the 24-color palette. Additionally, let's add a temporary button in the footer (subject to discussion with other maintainers for potential changes later) that will open a dialog. This dialog will allow users to switch between light/dark themes and between color palettes for color blindness.
Also, @horizenight and @ArnabBCA, would you like to collaborate on addressing issues #684 and #709?
Yes ,I would like collaborate on this issue i will provide the background colors and he can generate the color palettes based on that. After he as implemented the preferences Dialog and toggle colors based on the preferences i can make make it toggle based on the theme.
I am closing this issue as it has been inactive for a long time with no reported progress. While accessibility for our website is important, we will address it comprehensively after internal discussion.
Overview:
Web Content Accessibility Guidelines (WCAG) 2.1 are critical for ensuring that our website is inclusive and accessible to a diverse audience, including network scientists and students with disabilities. This issue outlines the importance of adhering to WCAG 2.1 standards and highlights specific challenges that individuals with disabilities may face when accessing visual content, such as line charts.
Why WCAG 2.1 Matters:
Addressing Challenges for Users with Disabilities:
Action Items:
Pre-Conclusion Guidelines:
Before creating any pull requests, please adhere to the following guidelines:
These guidelines are crucial to maintaining a collaborative and informed development process. Ensure that proposed changes are in line with our discussions and that you have a comprehensive understanding of the WCAG 2.1 guidelines for effective implementation.
Conclusion:
By prioritizing and implementing WCAG 2.1 guidelines, we are not only meeting regulatory requirements but also fostering an inclusive environment where network scientists and students with disabilities can engage with and benefit from the content on our website. This issue serves as a guide for understanding and addressing specific challenges related to visual content accessibility.