-
-
Notifications
You must be signed in to change notification settings - Fork 284
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Broken on Safari 14 #246
Comments
I'm also experiencing this on the latest version of Safari |
I don't own a mac nor have access to the latest Safari version (only v12) - You one of you describe what is happening in detail? Maybe there's an error message? Or is there a page where I can see all the changes from Safari 13 to Safari 14? |
There are no errors, it appears the actual values work fine the issue is actually rendering. If I resize the browser window it shows the correct colours: https://www.dropbox.com/s/45zzf88gcq68k7c/picker-safari-issue-2.mov?dl=0 Interestingly the Classic theme selection preview on the left hand side works fine: but it doesn't on Monolith: Clicking save on both only updates the button colour after resizing the browser (and other such interactions) |
Ugh, that is really strange (and difficult to fix without safari) - at least I won't be able to fix that, I'll mark this issue maybe someone else could take a look at it :) |
It works well on Safari version 13.1.2 (13609.3.5.1.5) BTW. |
That is definitely a Safari related bug. I was able to at least update the color after saving with this method:
But the problem still exists even on page load. The correct "default" color is not applied until the browser is either resized, or even when I toggle the console. I even tried |
I had this same issue. For me, the color text output in the bottom left was updating as I changed the slider, but the color block on the left wasn't. Same thing would happen when I clicked, sometimes, on two similar colors in the swatches. When the update occurred, I looked and it seemed to be setting the active-color block's color style instead of the background-color for some reason. I set an event listener:
When the color change event happened, I'd grab the active color element and set the background color instead of the color:
I didn't need opacity (but that's an easy addition) and only had one instance ever, so this worked for my needs. You could model your solution around this if you need. If it's setting the color style, maybe the solution here is to change the style being set from "color" to "background-color" in the color change method in Pickr? or both? |
Thanks @fjaxyu for the inspiration. For anyone else that has multiple picker instances, here's how I fixed it with just two lines:
I placed this in the save event handler, but you should be able to use this anywhere that you have access to the Pickr instance. |
@edwinfinch This works with all colors except
I tried a few things that came to mind, but was not able to get white working. Does it work for you with |
@edwinfinch I'd rather say that this is a safari-related bug where
Safari seems to ignore the computed part. What I found out with a friends laptop is that, if you resize the browser, the color does change. So Safari is missing a repaint cycle. A fix would be using CSS variables, I'll take a look at this on the next weekend. |
Still broken on Safari 14.0.3 (16610.4.3.1.7) |
@MrMooky @swaterfall @caspii @edwinfinch I just pushed an updated version with CSS Variables instead. Of course this means that IE11 support is completely gone but I never intented to support it anyways (and anyways, safari seems to be the new IE11). Since I don't have any device with safari on it, could you please verify if it's now working as expected? |
@simonwep I updated to this version and now color palettes are not visible. They still function, but are not previewed. This is on Windows 10. |
@Teraskull Huh, there are many browsers for windows 10, which one are you using? |
Edge Chromium Version 91.0.838.3 (Official build) dev (64-bit) |
Okay, it works on the stable version (89) so I don't consider this as a bug (this one is on edge and you're using a dev version, it's very likely that some things don't work there). After somebody tested it with a safari v13+ browser I'll release a new patch version and close this one. |
@simonwep My bad, I forgot to update the theme file as well, sorry for distraction :) |
@simonwep thanks for your efforts! Here's what I'm seeing on Version 14.0.3 (16610.4.3.1.7) |
@caspii would you be able to figure out what's wrong with the swatches and color-preview? I can imagine it'd take me quite some time to figure it out without being able to test it... |
@simonwep unfortunately I'm not a frontend-crack, but here's what I've found out:
|
Yes, unfortunately broken on safari 14 both desktop and mobile. |
What is the current behavior?
Save button doesn't function correctly and Button color not updating to reflect selection.
Please provide the steps to reproduce:
Use the demo https://simonwep.github.io/pickr/ on the latest version of Safari.
Your environment:
The text was updated successfully, but these errors were encountered: