Skip to content
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

fix: mitigate alert and confirm apis not working in embeded live preview in windows desktop #1750

Merged
merged 1 commit into from
Jul 15, 2024

Conversation

abose
Copy link
Member

@abose abose commented Jul 15, 2024

Address: https://github.com/orgs/phcode-dev/discussions/1734

tracking tauri issue: https://discordapp.com/channels/616186924390023171/1258736272814374964

In Windows desktop apps, DOM alert and Confirm api is not working from iframe. Prompt API works. It works as expected in Mac/Linux.

The fix is that since prompt api works, i have used a hack to use prompt api when someone calls alert(). Sine alert() pauses js ontext, this has to be done and we could not rely on a pure js rendered alert dialog box.

@phoenixide
Copy link
Member

Thank You for making this pull request.

Copy link

sonarcloud bot commented Jul 15, 2024

@abose abose merged commit 6cbae7e into main Jul 15, 2024
16 of 17 checks passed
@abose abose deleted the x branch July 15, 2024 08:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants