Skip to content
Snippets Groups Projects
Commit b69d04b9 authored by tobiasre's avatar tobiasre Committed by klamas
Browse files

feat: added original TÜ logo, fixed padding error #49

parent e49fbce8
No related branches found
No related tags found
1 merge request!53feat: added original TÜ logo, fixed padding error #49
frontend/app/components/assets/image.png

4.09 MiB

frontend/app/components/assets/tu.png

12.2 KiB

...@@ -9,7 +9,6 @@ import CloseIcon from "@/app/components/assets/CloseIcon"; ...@@ -9,7 +9,6 @@ import CloseIcon from "@/app/components/assets/CloseIcon";
import data from "../../data/en.json"; import data from "../../data/en.json";
const InfoModal = ({ show, onClose, details }) => { const InfoModal = ({ show, onClose, details }) => {
const questionTypes = useMemo(() => { const questionTypes = useMemo(() => {
if ( if (
!details?.questionConfigDetails || !details?.questionConfigDetails ||
...@@ -32,7 +31,7 @@ const InfoModal = ({ show, onClose, details }) => { ...@@ -32,7 +31,7 @@ const InfoModal = ({ show, onClose, details }) => {
)} )}
/> />
); );
}, [details.questionConfigDetails]); }, [details?.questionConfigDetails]);
const questionErrors = useMemo(() => { const questionErrors = useMemo(() => {
if ( if (
...@@ -57,7 +56,7 @@ const InfoModal = ({ show, onClose, details }) => { ...@@ -57,7 +56,7 @@ const InfoModal = ({ show, onClose, details }) => {
)} )}
/> />
); );
}, [details.questionErrors]); }, [details?.questionErrors]);
const questionWarnings = useMemo(() => { const questionWarnings = useMemo(() => {
if ( if (
...@@ -82,7 +81,7 @@ const InfoModal = ({ show, onClose, details }) => { ...@@ -82,7 +81,7 @@ const InfoModal = ({ show, onClose, details }) => {
)} )}
/> />
); );
}, [details.questionWarnings]); }, [details?.questionWarnings]);
return ( return (
<Modal show={show} onClose={onClose}> <Modal show={show} onClose={onClose}>
......
import Image from "next/image"; import Image from "next/image";
import tu from "@/app/components/assets/tu.png"; import image from "@/app/components/assets/image.png";
import data from "../../data/en.json"; import data from "../../data/en.json";
import Link from "next/link"; import Link from "next/link";
import Button from "../utils/Button"; import Button from "../utils/Button";
...@@ -10,13 +10,13 @@ export default function Navbar() { ...@@ -10,13 +10,13 @@ export default function Navbar() {
<Link <Link
href="/" href="/"
passHref passHref
className="sm:h-14 h-10 w-auto rounded-sm self-center sm:pl-10" className="sm:h-14 h-10 w-auto rounded-sm self-center sm:ml-10"
> >
<Image <Image
src={tu} src={image}
alt="logo" alt="logo"
priority priority
className="sm:h-14 h-10 w-auto rounded-sm self-center sm:pl-10" className="sm:h-14 h-10 w-auto rounded-sm self-center sm:ml-10"
href="/" href="/"
/> />
</Link> </Link>
......
import { toast } from "react-toastify";
import data from "../../data/en.json";
export const sendFileToBackend = async (file, outputFormat) => { export const sendFileToBackend = async (file, outputFormat) => {
const fileName = file[0]?.name.toLowerCase();
if (!fileName?.endsWith(".docx")) {
toast.error(data.fileupload.fileNotAcceptable, {
position: "bottom-right",
hideProgressBar: true,
});
throw new Error(data.fileupload.fileNotAcceptable);
}
const formData = new FormData(); const formData = new FormData();
formData.append("file", file[0]); formData.append("file", file[0]);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment