Retrospring/app/javascript/retrospring/features/webpush/dismiss.ts

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

8 lines
294 B
TypeScript
Raw Normal View History

export function dismissHandler (event: Event): void {
event.preventDefault();
const sender: HTMLButtonElement = event.target as HTMLButtonElement;
sender.closest<HTMLDivElement>('.push-settings').classList.add('d-none');
localStorage.setItem('dismiss-push-settings-prompt', 'true');
}