fix(isHexColor): add require_hashtag option#2535
Conversation
|
See my comment in #2533 (comment) |
|
thank you for the feedback! that makes sense. I'll implement the |
# prefix for Hexcolor validation in isHexColorrequire_hashtag option to isHexColor
|
@WikiRik |
WikiRik
left a comment
There was a problem hiding this comment.
Can you copy the 'default' test set to be checked against args: [{ require_hashtag: false }], as well? Just for completeness
|
@WikiRik done! |
require_hashtag option to isHexColorrequire_hashtag option
|
@rubiin : This change broke our upgrade from 13.9 (due to |
isHexColor: Enforce#prefix for Hexcolor validationDescription:
This PR updates the
isHexColorfunction in validator.js to enforce the presence of a # prefix for hex color validation. Previously, the function accepted both formats with and without #, leading to inconsistent behavior. Hex color codes are commonly expected to start with a #, so this change aligns the implementation with industry standards.Changes Made:
Checklist
Please let me know if further adjustments or additional tests are needed!