New to Telerik UI for ASP.NET Core? Download free 30-day trial

ASP.NET Core FlatColorPicker Contrast Tool

Loading Demo...
  • EXAMPLE
  • VIEW SOURCE
  • Edit in Telerik REPL
HtmlHelper
TagHelper
Files:
contrast_tool.cshtml
Contrast_ToolController.cs
Contrast_Tool_TagHelper.cshtml

Also available for:

CLIENT-SIDE API SERVER-SIDE API

Description

The FlatColorPicker component provides options for checking the color contrast ratio between two colors. Color contrast between text and background is important on web pages. It affects some people’s ability to perceive the information.

This tool follows the Web Content Accessibility Guidelines (WCAG), which are a series of recommendations for making the web more accessible.

Regarding colors, the WCAG standard defines two levels of contrast ratio:

  • AA (minimum contrast)—The level AA requires a contrast ratio of at least 4.5:1 for normal text.
  • AAA (enhanced contrast)—The level AAA requires a contrast ratio of at least 7:1 for normal text.

The example demonstrates how to display the Color Contrast Tool in the ColorPicker gradient popup.

Additional Apps

This FlatColorPicker example is part of unique collection of hundreds of ASP.NET Core demos, with which you can see all Telerik ASP.NET Core components and their features in action. View the source code of the demos from the library or directly adapt, and edit them and their theme appearance in Telerik REPL for ASP.NET Core or ThemeBuilder.

Support & Learning Resources

Additional Resources