Ishadijcks / MooLite

Open source Milky Way Idle client
11 stars 4 forks source link

Equipment Exporter Bugfix #132

Closed AmVoidGuy closed 1 year ago

AmVoidGuy commented 1 year ago

fix(EquipmentExporter): Better clipboard handling, so copying works on more devices.

Ishadijcks commented 1 year ago

Void in Discord:

For whatever reason, adding in the .then() handler fixes the issue with some browsers. Don't really know exactly why, just some asynchronous junk that some browsers or devices don't handle correctly otherwise I guess? The try / catch is just for better clarity if it doesn't work for some other reason so people know it wasn't actually copied.
---
Yeah, I believe the specific issue was that the alert was taking focus off of the document and onto the alert box instead before the clipboard was finished since it's an async event. Some browsers or devices don't handle that well, so waiting to fulfill the promise and then sending out the alert solves that issue
github-actions[bot] commented 1 year ago

:tada: This PR is included in version 1.4.5 :tada:

The release is available on GitHub release

Your semantic-release bot :package::rocket: