feat: add push notification settings to user profile and update related functionality
All checks were successful
Chore App Build, Test, and Push Docker Images / build-and-push (push) Successful in 2m50s

This commit is contained in:
2026-04-20 10:43:09 -04:00
parent fd28c89cbf
commit b529ddaa02
8 changed files with 249 additions and 191 deletions

View File

@@ -15,7 +15,7 @@ import {
import { getCachedImageUrl, getCachedImageBlob } from '@/common/imageCache'
import '@/assets/styles.css'
import ModalDialog from './ModalDialog.vue'
import { subscribeToPushWithResult } from '@/services/pushSubscription'
import { subscribeToPushWithResult, isPushOptedOut } from '@/services/pushSubscription'
const router = useRouter()
const show = ref(false)
@@ -140,7 +140,9 @@ const submit = async () => {
}
// Authenticate parent and navigate
authenticateParent(stayInParentMode.value)
subscribeToPushWithResult() // fire-and-forget — browser gesture is satisfied by the PIN button click
if (!isPushOptedOut()) {
subscribeToPushWithResult() // fire-and-forget — browser gesture is satisfied by the PIN button click
}
close()
const returnUrl = consumePendingReturnUrl()
router.push(returnUrl || '/parent')