We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 58d695f commit 8f73078Copy full SHA for 8f73078
src/app.ts
@@ -37,7 +37,7 @@ function isValidGitHubUsername(username: string): boolean {
37
38
/** Validates hex color format (with or without #) */
39
function isValidHexColor(color: string): boolean {
40
- return /^#?[0-9a-fA-F]{6}$/.test(color);
+ return /^#?([0-9a-fA-F]{3}|[0-9a-fA-F]{6})$/.test(color);
41
}
42
43
/* --- Routes --- */
0 commit comments