buttercup / buttercup-desktop

:key: Cross-Platform Passwords & Secrets Vault
https://buttercup.pw
GNU General Public License v3.0
4.31k stars 330 forks source link

Ctrl-C copies the previously selected entry's password, not the current one #1384

Open stuartm opened 1 month ago

stuartm commented 1 month ago

Context: So I've just updated to the latest and greatest Buttercup release (from 1.2.0) after learning that my most wished feature of copying passwords quickly and effectively via keyboard shortcuts had been added sometime in the past year.

I've just tested out the feature only to find it's not working correctly. Consistently when I hit Ctrl-C and paste in plain text to check results it has copied the password of the previously selected entry and not the currently selected entry.

perry-mitchell commented 1 month ago

The current copy functionality isn't ideal in terms of it's base assumption - that the selected entry is the one to copy. Selection is still maintained by actual HTML focus, which can differ from the highlighted entry. For me at least clicking the entry I want to copy the password of works, but I believe you that you're experiencing bogus results when using the hotkey.

Ideally we'd track the selected entry and, upon hitting copy, copy its password instead.