Skip to content

Open-source event management and ticket selling platform — perfect for concerts, conferences, and everything in between 🎟️ If you find this project helpful, please consider giving us a star ⭐️

Fix widget color validation rejecting uppercase hex values (#1103)

Dave Earley64ca9e9fdaca
diff --git a/frontend/src/components/common/WidgetEditor/index.tsx b/frontend/src/components/common/WidgetEditor/index.tsx
index dd6da2522..f95f96a5b 100644
--- a/frontend/src/components/common/WidgetEditor/index.tsx
+++ b/frontend/src/components/common/WidgetEditor/index.tsx
@@ -17,7 +17,7 @@ export const WidgetEditor = () => {
const eventQuery = useGetEvent(eventId);
const colorMessage = t`Color must be a valid hex color code. Example: #ffffff`;
- const colorRegex = /^#([0-9a-f]{3,4}|[0-9a-f]{6}|[0-9a-f]{8})$/;
+ const colorRegex = /^#([0-9a-f]{3,4}|[0-9a-f]{6}|[0-9a-f]{8})$/i;
const {data: eventSettings, isFetched: isEventSettingsFetched} = useGetEventSettings(eventId);
const form = useForm({
initialValues: {