Wondermarin / react-color-palette

🎨 Lightweight Color Picker component for React.
https://codesandbox.io/s/react-color-palette-2zw8q
MIT License
272 stars 29 forks source link

Components are unresponsive in environments where pointer events are not supported #78

Closed g-hor closed 1 month ago

g-hor commented 1 month ago

My Environment

I am currently developing in a browser environment that doesn't support pointer events.

Dependency Version
ts-node version v10.9.1
react-color-palette version v7.1.0

Expected Behavior:

As a user, I should be able to click and drag across any of the color palette components to update a color value.

Actual Behavior:

The color palette components do not seem to register any events from any click or drag actions. The color value remains unchanged, and the color cursor remains at the same position of its initial state.

Additional Context:

My development environment is quite niche, as I am creating a plugin for Adobe Illustrator. I'll include some more context in case it's helpful for debugging purposes:

In Illustrator, plugins use CEP 11, which is based on a version of Chromium (v.88) that actually does support pointer events. However, there is a known issue with CEP where pointer events are not fired correctly on MacOS. This has been an issue for years, and it seems a fix will not be implemented anytime in the foreseeable future.

Wondermarin commented 1 month ago

The problem indeed seems very niche. I can try to fix it, and the solution I see for now is to completely avoid pointer events in the CEP environment. However, since I've never worked in this environment before, it might take more time to implement.

g-hor commented 1 month ago

@Wondermarin Thanks for your quick response! Although my development environment is probably the edgiest of edge cases, I would like to note that this issue may still be relevant in other environments/browsers where pointer events aren't necessarily supported.

Wondermarin commented 1 month ago

Yes, potentially such an issue might arise in older environments; however, I believe that having 96%+ support is sufficient to rely on this API. I aim to support environments that were released after Chromium 77, and since your environment is based on Chromium 88, and the issue is a specific case, support for it will be added.

g-hor commented 1 month ago

Awesome, thanks for hearing me out. I understand this is low priority, but feel free to reach out to me if you'd like any more details (I have notifications enabled for this Issue). Looking forward to your fix!

Wondermarin commented 1 month ago

Please check v7.2.2. If the issue has been resolved in this version, I'll go ahead and close it.

g-hor commented 1 month ago

Please don't take this the wrong way, but I want to give you a big big hug. Thank you so much for your super quick response!!! You're amazing!