feat: replace success modal with non-blocking toast notification
feat: add global event listener for mannschaften updates in Navigation component feat: notify app of mannschaften changes after CSV save and handle visibility changes refactor: remove unused anlagen page fix: update CmsMannschaften reference in sportbetrieb page for reactivity fix: enhance authentication token retrieval in passkey API endpoints feat: implement refresh session and access token generation for Android clients in passkey login fix: unify token retrieval method across passkey API endpoints feat: add MediaTypes utility for JSON content type in Android app feat: create PasskeyRepository for handling passkey authentication and registration in Android app feat: add validated text field and rich text components for Android UI feat: implement newsletter subscription and unsubscription screens in Android app feat: create public pages including Impressum with dynamic content loading
This commit is contained in:
@@ -1,43 +1,14 @@
|
||||
<template>
|
||||
<!-- Success Modal -->
|
||||
<!-- Success Toast (bottom) -->
|
||||
<div
|
||||
v-if="showSuccess"
|
||||
class="fixed inset-0 bg-black bg-opacity-50 flex items-center justify-center z-50 p-4"
|
||||
@click.self="closeSuccess"
|
||||
v-if="showSuccessToast"
|
||||
class="fixed left-0 right-0 mx-auto max-w-3xl z-50 pointer-events-none"
|
||||
style="bottom:72px;"
|
||||
>
|
||||
<div class="bg-white rounded-lg max-w-md w-full p-6">
|
||||
<div class="flex items-center mb-4">
|
||||
<div class="flex-shrink-0 w-10 h-10 mx-auto bg-green-100 rounded-full flex items-center justify-center">
|
||||
<svg
|
||||
class="w-6 h-6 text-green-600"
|
||||
fill="none"
|
||||
stroke="currentColor"
|
||||
viewBox="0 0 24 24"
|
||||
>
|
||||
<path
|
||||
stroke-linecap="round"
|
||||
stroke-linejoin="round"
|
||||
stroke-width="2"
|
||||
d="M5 13l4 4L19 7"
|
||||
/>
|
||||
</svg>
|
||||
</div>
|
||||
</div>
|
||||
<div class="text-center">
|
||||
<h3 class="text-lg font-medium text-gray-900 mb-2">
|
||||
{{ successTitle }}
|
||||
</h3>
|
||||
<p class="text-sm text-gray-600 mb-6">
|
||||
{{ successMessage }}
|
||||
</p>
|
||||
<div class="flex justify-center">
|
||||
<button
|
||||
class="px-6 py-2 bg-primary-600 hover:bg-primary-700 text-white rounded-lg transition-colors"
|
||||
@click="closeSuccess"
|
||||
>
|
||||
OK
|
||||
</button>
|
||||
</div>
|
||||
<div class="pointer-events-auto mx-4 shadow-lg rounded-md overflow-hidden">
|
||||
<div class="px-4 py-3 bg-green-50 text-green-800 text-sm">
|
||||
<div class="font-medium">{{ toastTitle }}</div>
|
||||
<div class="mt-1">{{ toastMessage }}</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -138,14 +109,14 @@
|
||||
<script setup>
|
||||
import { ref } from 'vue'
|
||||
|
||||
// Modal States
|
||||
const showSuccess = ref(false)
|
||||
// Modal / Toast States
|
||||
const showSuccessToast = ref(false)
|
||||
const showError = ref(false)
|
||||
const showConfirm = ref(false)
|
||||
|
||||
// Modal Content
|
||||
const successTitle = ref('')
|
||||
const successMessage = ref('')
|
||||
// Modal / Toast Content
|
||||
const toastTitle = ref('')
|
||||
const toastMessage = ref('')
|
||||
const errorTitle = ref('')
|
||||
const errorMessage = ref('')
|
||||
const confirmTitle = ref('')
|
||||
@@ -153,10 +124,14 @@ const confirmMessage = ref('')
|
||||
const confirmAction = ref(null)
|
||||
|
||||
// Modal Functions
|
||||
let toastTimeout = null
|
||||
const showSuccessModal = (title, message) => {
|
||||
successTitle.value = title
|
||||
successMessage.value = message
|
||||
showSuccess.value = true
|
||||
// Show non-blocking toast at bottom instead of modal dialog
|
||||
toastTitle.value = title || 'Erfolg'
|
||||
toastMessage.value = message || ''
|
||||
showSuccessToast.value = true
|
||||
if (toastTimeout) clearTimeout(toastTimeout)
|
||||
toastTimeout = setTimeout(() => { showSuccessToast.value = false; toastTimeout = null }, 3500)
|
||||
}
|
||||
|
||||
const showErrorModal = (title, message) => {
|
||||
@@ -173,7 +148,8 @@ const showConfirmModal = (title, message, action) => {
|
||||
}
|
||||
|
||||
const closeSuccess = () => {
|
||||
showSuccess.value = false
|
||||
showSuccessToast.value = false
|
||||
if (toastTimeout) { clearTimeout(toastTimeout); toastTimeout = null }
|
||||
}
|
||||
|
||||
const closeError = () => {
|
||||
|
||||
Reference in New Issue
Block a user