Skip to content

An open-source, self-hostable PaaS alternative to Vercel, Heroku & Netlify that lets you easily deploy static sites, databases, full-stack applications and 360+ one-click services on your own servers.

fix: copy the right text

peaklabs-dev9701c8aa6b6b
diff --git a/resources/views/components/modal-confirmation.blade.php b/resources/views/components/modal-confirmation.blade.php
index 6f1dad8c98..4620d35ed6 100644
--- a/resources/views/components/modal-confirmation.blade.php
+++ b/resources/views/components/modal-confirmation.blade.php
@@ -92,8 +92,9 @@
});
},
copyConfirmationText() {
+ const textToCopy = this.confirmationText;
if (navigator.clipboard && window.isSecureContext) {
- navigator.clipboard.writeText(this.confirmationText)
+ navigator.clipboard.writeText(textToCopy)
.then(() => {
this.copied = true;
setTimeout(() => {
@@ -102,7 +103,7 @@
});
} else {
const textarea = document.createElement('textarea');
- textarea.value = this.confirmationText;
+ textarea.value = textToCopy;
textarea.style.position = 'fixed';
textarea.style.opacity = '0';
document.body.appendChild(textarea);