From 584d2bf422dc1758ed369cd791b18aaeb80e296c Mon Sep 17 00:00:00 2001 From: EwoutV Date: Tue, 9 Apr 2024 20:06:01 +0200 Subject: [PATCH] chore: linting --- frontend/src/components/projects/ProjectCard.vue | 14 +++++++++++--- frontend/src/components/projects/ProjectList.vue | 12 ++++-------- frontend/src/views/courses/UpdateCourseView.vue | 6 +++--- .../views/courses/roles/AssistantCourseView.vue | 1 - .../src/views/courses/roles/StudentCourseView.vue | 1 - .../src/views/courses/roles/TeacherCourseView.vue | 2 -- 6 files changed, 18 insertions(+), 18 deletions(-) diff --git a/frontend/src/components/projects/ProjectCard.vue b/frontend/src/components/projects/ProjectCard.vue index f5982bbd..d462a283 100644 --- a/frontend/src/components/projects/ProjectCard.vue +++ b/frontend/src/components/projects/ProjectCard.vue @@ -40,11 +40,13 @@ const { t } = useI18n(); diff --git a/frontend/src/components/projects/ProjectList.vue b/frontend/src/components/projects/ProjectList.vue index cbd41302..85571b7e 100644 --- a/frontend/src/components/projects/ProjectList.vue +++ b/frontend/src/components/projects/ProjectList.vue @@ -14,7 +14,7 @@ const props = withDefaults( }>(), { courses: () => [], - showPast: false + showPast: false, }, ); @@ -25,21 +25,17 @@ const { projects, getProjectsByCourse } = useProject(); /* State */ // The merged projects from all courses -const allProjects = computed(() => - props.courses.flatMap((course) => course.projects) -); +const allProjects = computed(() => props.courses.flatMap((course) => course.projects)); /** * Sorts the projects by deadline */ const sortedProjects = computed(() => { const projects = allProjects.value.filter((project) => - !props.showPast ? moment(project.deadline).isAfter() : true + !props.showPast ? moment(project.deadline).isAfter() : true, ); - return [...projects].sort((a, b) => - new Date(a.deadline).getTime() - new Date(b.deadline).getTime() - ) + return [...projects].sort((a, b) => new Date(a.deadline).getTime() - new Date(b.deadline).getTime()); }); /* Watchers */ diff --git a/frontend/src/views/courses/UpdateCourseView.vue b/frontend/src/views/courses/UpdateCourseView.vue index 6e164bf5..5813d8c1 100644 --- a/frontend/src/views/courses/UpdateCourseView.vue +++ b/frontend/src/views/courses/UpdateCourseView.vue @@ -23,10 +23,10 @@ onMounted(async () => { await getCourseByID(params.courseId as string); /* Set the form values */ - if (course.value !== null){ + if (course.value !== null) { form.name = course.value.name; form.description = course.value.description ?? ''; - form.year = `${course.value.academic_startyear} - ${course.value.academic_startyear + 1}` + form.year = `${course.value.academic_startyear} - ${course.value.academic_startyear + 1}`; } }); @@ -95,7 +95,7 @@ const submitCourse = async (): Promise => {
- +
diff --git a/frontend/src/views/courses/roles/AssistantCourseView.vue b/frontend/src/views/courses/roles/AssistantCourseView.vue index edb81cee..25444fe2 100644 --- a/frontend/src/views/courses/roles/AssistantCourseView.vue +++ b/frontend/src/views/courses/roles/AssistantCourseView.vue @@ -11,7 +11,6 @@ const props = defineProps<{ /* Composable injections */ const { t } = useI18n(); -