[WEB-3745] fix: color picker event propagation (#6859)

This commit is contained in:
Anmol Singh Bhatia 2025-04-02 17:35:04 +05:30 committed by GitHub
parent 523ab3f4a1
commit 0db581509c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -12,7 +12,9 @@ export const ColorPicker: React.FC<ColorPickerProps> = (props) => {
const inputRef = React.useRef<HTMLInputElement>(null);
// handlers
const handleOnClick = () => {
const handleOnClick = (e: React.MouseEvent<HTMLButtonElement>) => {
e.stopPropagation();
e.preventDefault();
inputRef.current?.click();
};