feat: Add js to close notifications
This commit is contained in:
		@@ -18,4 +18,15 @@ document.addEventListener('DOMContentLoaded', () => {
 | 
			
		||||
    });
 | 
			
		||||
  });
 | 
			
		||||
 | 
			
		||||
});
 | 
			
		||||
 | 
			
		||||
// Looks for all notifications with a delete and allows closing them when pressing delete
 | 
			
		||||
document.addEventListener('DOMContentLoaded', () => {
 | 
			
		||||
  (document.querySelectorAll('.notification .delete') || []).forEach(($delete) => {
 | 
			
		||||
    const $notification = $delete.parentNode;
 | 
			
		||||
 | 
			
		||||
    $delete.addEventListener('click', () => {
 | 
			
		||||
      $notification.parentNode.removeChild($notification);
 | 
			
		||||
    });
 | 
			
		||||
  });
 | 
			
		||||
});
 | 
			
		||||
		Reference in New Issue
	
	Block a user