Browse Source

Editor: cleanup and feedback

imwald
Nuša Pukšič 2 weeks ago
parent
commit
78cca0c10a
  1. 12
      assets/controllers/nostr/nostr_publish_controller.js

12
assets/controllers/nostr/nostr_publish_controller.js

@ -516,12 +516,24 @@ export default class extends Controller { @@ -516,12 +516,24 @@ export default class extends Controller {
if (this.hasStatusTarget) {
this.statusTarget.innerHTML = `<div class="alert alert-info">${message}</div>`;
}
// Clear status after 3 seconds
setTimeout(() => {
if (this.hasStatusTarget) {
this.statusTarget.innerHTML = '';
}
}, 3000);
}
showSuccess(message) {
if (this.hasStatusTarget) {
this.statusTarget.innerHTML = `<div class="alert alert-success">${message}</div>`;
}
// Clear status after 3 seconds
setTimeout(() => {
if (this.hasStatusTarget) {
this.statusTarget.innerHTML = '';
}
}, 3000);
}
showError(message) {

Loading…
Cancel
Save