Variation | Pattern | |
---|---|---|
Hex (standalone) | ^(#([a-fA-F0-9]{6}|[a-fA-F0-9]{3}))$ | |
Hex (inline) | \b(#([a-fA-F0-9]{6}|[a-fA-F0-9]{3}))\b |
{ "featured": true, "handle": "css-color", "title": "CSS Colors", "tags": [ "color", "css", "html" ], "variations": [ { "title": "Hex (standalone)", "regex": "^(#([a-fA-F0-9]{6}|[a-fA-F0-9]{3}))$", "inputs": [ "#f00", "#ff0000", "#0f0", "#00ff00", "#00f", "#0000ff", "#000", "#000000", "#fff", "#ffffff" ] }, { "title": "Hex (inline)", "regex": "\\b(#([a-fA-F0-9]{6}|[a-fA-F0-9]{3}))\\b", "inputs": [ "My favorite color is #f00!" ] } ], "fullPath": "/app/patterns/color.yaml" }