control-color-alpha icon indicating copy to clipboard operation
control-color-alpha copied to clipboard

The example code on readme file fails to sanitize rgb color.

Open majeedraza1 opened this issue 3 years ago • 0 comments

On README.md you gave some sample code to sanitize color. But when I was testing I found that it fails to sanitize rgb color.

Later I found the pattern is used for sanitizing rgb color is missing closing bracket.

Here is my solution. Please check this and update README.md file.

rgb\(((\d{1,2}|1\d\d|2([0-4]\d|5[0-5]))\s*,\s*){2}((\d{1,2}|1\d\d|2([0-4]\d|5[0-5]))\s*)\)

majeedraza1 avatar Dec 06 '21 16:12 majeedraza1