paulca / paulca.com Public
| 1 | import { Controller } from "@hotwired/stimulus"; |
| 2 | |
| 3 | export default class extends Controller { |
| 4 | connect() { |
| 5 | setTimeout(() => { |
| 6 | this.element.style.transition = "opacity 0.5s ease-out"; |
| 7 | this.element.style.opacity = "0"; |
| 8 | |
| 9 | setTimeout(() => { |
| 10 | this.element.remove(); |
| 11 | }, 500); |
| 12 | }, 2000); |
| 13 | } |
| 14 | } |