diff --git a/src/features/Events/AttendanceValidation/EventCounterModal.tsx b/src/features/Events/AttendanceValidation/EventCounterModal.tsx index 9e6060c..16e3007 100644 --- a/src/features/Events/AttendanceValidation/EventCounterModal.tsx +++ b/src/features/Events/AttendanceValidation/EventCounterModal.tsx @@ -4,6 +4,7 @@ import { DateTimeFields } from "@/components/Event/components/DateTimeFields"; import { FieldWithLabel } from "@/components/Event/components/FieldWithLabel"; import { splitDateTime } from "@/components/Event/utils/dateTimeHelpers"; import { Box, Button, TextField, Typography } from "@linagora/twake-mui"; +import { SnackbarAlert } from "@/components/Loading/SnackBarAlert"; import moment from "moment-timezone"; import { useEffect, useState } from "react"; import { useI18n } from "twake-i18n"; @@ -22,6 +23,7 @@ export function EventCounterModal({ }) { const { t } = useI18n(); const [isSubmitting, setIsSubmitting] = useState(false); + const [showSuccessToast, setShowSuccessToast] = useState(false); const allday = contextualizedEvent.event.allday ?? false; @@ -128,6 +130,7 @@ export function EventCounterModal({ : `${endDate}T${endTime}`, message, }); + setShowSuccessToast(true); setOpen(false); } catch (error) { console.error(error); @@ -150,94 +153,104 @@ export function EventCounterModal({ }, [open, startSplit.date, startSplit.time, endSplit.date, endSplit.time]); return ( - setOpen(false)} - title={t("eventPreview.proposeNewTime")} - > - {/* Event title */} - - - {formatEventChipTitle(contextualizedEvent.event, t)} - - - - {/* Current event time */} - - + + setOpen(false)} + title={t("eventPreview.proposeNewTime")} + > + {/* Event title */} + + + {formatEventChipTitle(contextualizedEvent.event, t)} + + - {/* Your proposal label */} - - setShowMore((prev) => !prev)} - /> - - {/* Optional message */} - - setMessage(e.target.value)} - sx={{ - mt: 2, - "& .MuiInputBase-root": { - overflowY: "auto", - padding: 0, - }, - "& textarea": { - resize: "vertical", - }, - }} - /> - + {/* Current event time */} - {/* Actions */} - - - - - + setShowMore((prev) => !prev)} + /> + + {/* Optional message */} + + setMessage(e.target.value)} + sx={{ + mt: 2, + "& .MuiInputBase-root": { + overflowY: "auto", + padding: 0, + }, + "& textarea": { + resize: "vertical", + }, + }} + /> + + + {/* Actions */} + + + + + + ); } diff --git a/src/locales/en.json b/src/locales/en.json index 9cfb78d..0fc830c 100644 --- a/src/locales/en.json +++ b/src/locales/en.json @@ -286,6 +286,7 @@ "yourProposal": "Your proposal", "optionalMessage": "Add optional message to the organizer", "sendProposal": "Send proposal", + "proposalSubmitted": "New time proposal submitted", "ACCEPTED": "Yes", "TENTATIVE": "Maybe", "DECLINED": "No", diff --git a/src/locales/fr.json b/src/locales/fr.json index 2b2cb2d..1c4f98c 100644 --- a/src/locales/fr.json +++ b/src/locales/fr.json @@ -287,6 +287,7 @@ "yourProposal": "Votre proposition", "optionalMessage": "Ajouter un message optionnel à l'organisateur", "sendProposal": "Envoyer la proposition", + "proposalSubmitted": "Proposition de nouvel horaire envoyée", "ACCEPTED": "Oui", "TENTATIVE": "Peut-être", "DECLINED": "Non", diff --git a/src/locales/ru.json b/src/locales/ru.json index efe581b..4a8b792 100644 --- a/src/locales/ru.json +++ b/src/locales/ru.json @@ -287,6 +287,7 @@ "yourProposal": "Ваше предложение", "optionalMessage": "Добавить необязательное сообщение организатору", "sendProposal": "Отправить предложение", + "proposalSubmitted": "Новое предложение по времени отправлено", "ACCEPTED": "Да", "TENTATIVE": "Возможно", "DECLINED": "Нет", diff --git a/src/locales/vi.json b/src/locales/vi.json index 707256e..27d9563 100644 --- a/src/locales/vi.json +++ b/src/locales/vi.json @@ -285,6 +285,7 @@ "yourProposal": "Đề xuất của bạn", "optionalMessage": "Thêm tin nhắn tùy chọn cho người tổ chức", "sendProposal": "Gửi đề xuất", + "proposalSubmitted": "Đề xuất thời gian mới đã được gửi", "ACCEPTED": "Có", "TENTATIVE": "Có thể", "DECLINED": "Không",