signature_pad
signature_pad copied to clipboard
iphone X and 12 issue
Hi!
Signature Pad don't work on iphone X and iphone 12, when I try write something I have instant refresh.
@2.3.2 from cdn.jsdelivr.net/npm/[email protected]/dist/signature_pad.min.js
thanks for help!
Link to movie showing bug: http://umotivo.pl/1.MOV
url to platform: http://przychodnia.klitom4.stronazen.pl/
Unfortunately I don't have an iPhone to test this on. It seems to work fine on Android.
If anyone has the ability to test this and find a fix please create a PR.
Out of curiosity I used AWS Device Farm to try this on an iPhone 12 running iOS 14.8. It worked correctly, both with our app and also the OP's app. So we might need to get more details on how to reproduce the problem reliably? I'll be glad to contribute if we end up identifying an issue.
@larrymcp @UziTech You have to be running on iOS 15.
iPhone 11 Pro running 15 on browser stack:
https://user-images.githubusercontent.com/10186520/142037332-53d9f539-1ce1-498a-94b9-e509f234d9e6.mov
iPhone 12 running 14.7 on browser stack:
https://user-images.githubusercontent.com/10186520/142037540-077f4bfd-4ae8-4ffc-a493-af03ea496b06.mov
I also confirmed it doesn't work on my personal iPhone 11 running v15, and it works on my wife's iPhone 11 running v14.
Unfortunately I do not have a fix, just wanted to help provide data.
it seems like the move events aren't being triggered. If this is something the browser does for privacy I don't think there is anything we can do to fix it. Unfortunately Safari has made choices to prioritize privacy over usability of it's web browser and I think this is a consequence.
@mcrowder65 thank you so much for that bit of information, pointing the way to iOS v15. I just ran some more tests too, on BrowserStack using that same device iPhone 11 Pro with iOS v15.
I think there are some signs of hope here! I noticed that:
(1) Frequently it will let you draw several lines before the screen-clearing problem occurs, as shown in @mcrowder65 's first video. That's good news because it doesn't appear to be the result of some restriction that Safari deliberately implemented. The screen-clearing happens at random times, and during my testing it was sometimes even quite rare.
(2) I can't get the screen-clearing problem to occur in our own installation of Signature_Pad. It occurs in the demo with moderate frequency, and it occurs in @umotivo-official 's app with high frequency, but in our own app I can't get it to occur at all. So that's good news too: if it sometimes works correctly on iOS v15, then apparently the problem only occurs with particular combinations of implementation settings.
The clearing is almost certainly an issue with the canvas resizing because a toolbar moves. Every time a canvas is resized safari clears it and I don't think there is any way for us to detect that. (I believe this is all browsers not just safari). @larrymcp your app must use a set width and height for the canvas (so there is no resizing) where the demo is based on the screen size.
Ah, excellent sleuthing and yes our app uses a fixed size.
If clearing on resize is the issue you can do the following:
window.addEventListener("resize", () => {
signaturePad.fromData(signaturePad.toData());
});
thanks a lot! I try Your solutions and back with feedback!
Hi!
Signature Pad don't work on iphone X and iphone 12, when I try write something I have instant refresh.
@2.3.2 from cdn.jsdelivr.net/npm/[email protected]/dist/signature_pad.min.js
thanks for help!
Hey, were you able to find a solution on this? library not working on ios safari. When you try to scribble it scrolls the entire page up/down. Desperate to find a solution!
Hi, I weren't able to find a solution.
Waiting for the official bugfix.
Hi! Signature Pad don't work on iphone X and iphone 12, when I try write something I have instant refresh. @2.3.2 from cdn.jsdelivr.net/npm/[email protected]/dist/signature_pad.min.js thanks for help!
Hey, were you able to find a solution on this? library not working on ios safari. When you try to scribble it scrolls the entire page up/down. Desperate to find a solution!
Is this fixed in the latest release?
Is this fixed in the latest release?
Doesn't seem like. Tested demo on iPhone 13 iOS 15.4.
Once the bar is triggered thru scrolling, signature disappears.
Edit: If website is added to homescreen and started as webapp, no url-bar is shown and signature pad works fine.
Safari on iOS will trigger the resize event when the 'address bar' disappears/appears after scrolling, this can be considered normal behaviour because the viewport changes in height.
A solution in this case could be to keep track of the screen width and only perform a 'clear signature' action when the width is changed.
I am facing an issue while rotating Signature pad in IOS version 16 and above.I try to find the root cause issue but didn't get any positive response is there any solution to resolve this issue kindly help me to resolve this issue ASAP.
Please find the link https://drive.google.com/file/d/1sKI2ObIYSt-dPcaQBGFMS1fvt5HVqm2m/view?usp=share_link
@AjeethSG have you tried https://github.com/szimek/signature_pad#handling-canvas-resize
@UziTech Hi Team, Ill tried already that canvas resize. Its worked up to iOS version 16 below. When rotating the Signature pad on iOS version 16 and above, I am experiencing problems with the rotation of the screen. It rotates a screen after enabling 'shake a undo' option. But I want to rotate a screen without enabling the option. In this case, I have tried to find the root cause of the error, but I have been unable to find it. The question that I would like to ask in this case is, can you please confirm, is this a issue? And How can this issue be resolved, and do you have any suggestions on how to do this? Kindly assist me to resolve this issue asap.
@AjeethSG what exactly is the issue you are seeing. In your video it looks like it doesn't disappear when it rotates.
@UziTech While trying to rotate the screen in iOS version 16, there was an error. The rotation doesn't work until we shake the phone and then it rotates smoothly. But in older versions of iOS below 16, it used to work fine, and I'm only experiencing this issue since the recent update. Kindly assist me to resolve this issue ASAP.
That seems like an iOS issue not a signature_pad issue. We don't do anything to prevent the screen from rotating. You would be better off asking somewhere else.
I'm going to close this issue as there doesn't seem to be a clear issue. If the original issue still happens please create a new issue with more details.