fix<utils>: Color Regular Error (#2567)

This commit is contained in:
luocong2016 2023-02-22 18:30:46 +08:00 committed by GitHub
parent d88915bac3
commit d6fdfd9f93
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -6,7 +6,7 @@
* @return Boolean
*/
export function isHexColor(color: string) {
const reg = /^#([0-9a-fA-F]{3}|[0-9a-fA-f]{6})$/;
const reg = /^#([0-9a-fA-F]{3}|[0-9a-fA-F]{6})$/;
return reg.test(color);
}