prop name changed 📛

This commit is contained in:
Ansari
2023-05-15 15:43:29 +05:30
parent 9b993c08f1
commit 8bf6594cf4

View File

@ -19,7 +19,7 @@ type DialogProps = {
formValues: FormValue[]; formValues: FormValue[];
setLoading: (loading: boolean) => void; setLoading: (loading: boolean) => void;
icon: React.ReactNode; icon: React.ReactNode;
trunate: boolean; trunateTitle: boolean;
}; };
export function Dialog({ export function Dialog({
@ -30,13 +30,13 @@ export function Dialog({
formValues, formValues,
setLoading, setLoading,
icon, icon,
trunate = true, trunateTitle = true,
}: DialogProps) { }: DialogProps) {
const unsentEmailsLength = formValues.filter( const unsentEmailsLength = formValues.filter(
(s: any) => s.email && s.sendStatus != "SENT" (s: any) => s.email && s.sendStatus != "SENT"
).length; ).length;
if (trunate && document.title.length > 20) { if (trunateTitle && document.title.length > 20) {
document.title = document.title.substring(0, 7) + "..." + document.title = document.title.substring(0, 7) + "..." +
document.title.substring(document.title.length - 7); document.title.substring(document.title.length - 7);
} }