mirror of
https://github.com/schlagmichdoch/PairDrop.git
synced 2025-04-20 15:06:15 -04:00
fix #112 and differentiate between textContent and innerText
This commit is contained in:
parent
27bf0fa74f
commit
520b772bc8
4 changed files with 6 additions and 6 deletions
|
@ -1420,7 +1420,7 @@ class ReceiveTextDialog extends Dialog {
|
|||
}
|
||||
|
||||
async _onCopy() {
|
||||
await navigator.clipboard.writeText(this.$text.textContent);
|
||||
await navigator.clipboard.writeText(this.$text.innerText);
|
||||
Events.fire('notify-user', 'Copied to clipboard');
|
||||
this.hide();
|
||||
}
|
||||
|
@ -1595,7 +1595,7 @@ class Toast extends Dialog {
|
|||
|
||||
_onNotify(message) {
|
||||
if (this.hideTimeout) clearTimeout(this.hideTimeout);
|
||||
this.$el.textContent = message;
|
||||
this.$el.innerText = message;
|
||||
this.show();
|
||||
this.hideTimeout = setTimeout(_ => this.hide(), 5000);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue