pickr: Broken on Safari 14
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:
Version (see Pickr.version): 1.7.2
Used bundle (es5 or normal one): Both
Used theme (default is classic): All
Browser-version: Safari 14.0 (15610.1.28.1.9, 15610)
Operating-system: macOS 10.15.6 (19G2021)
About this issue
- Original URL
- State: open
- Created 4 years ago
- Reactions: 3
- Comments: 22 (7 by maintainers)
@edwinfinch I’d rather say that this is a safari-related bug where
currentColordoes not update whencolorshould trigger a re-paint. It wouldn’t be the first time Safari doesn’t follow a spec or behaves in a weird way hence I would only call that a “browser-quirk”, it’s not a general bug. Changing color should changecurrentColorand thereforebackground. It’s part of the spec: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.
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
$(window).trigger('resize')after initialising, but without luck. It even works if I open it in Safari, open another window (any other app) and then return to Safari. Really strange.@Simonwep My bad, I forgot to update the theme file as well, sorry for distraction 😃
Still broken on Safari 14.0.3 (16610.4.3.1.7)