fix: TS errors, serialize calls, unused imports, pre-commit hook
Build & Deploy / build (push) Successful in 32s
Build & Deploy / docker (push) Successful in 1m42s

This commit is contained in:
Kevin
2026-07-07 20:49:52 +02:00
parent 15d3a13d0a
commit c4cad4f875
16 changed files with 27 additions and 101 deletions
-5
View File
@@ -9,7 +9,6 @@ const { props } = usePage<{
errors: Record<string, string>
}>()
const { components, states } = props
const errors = computed(() => props.errors || {})
const componentTypeOrder = [
'Processor',
@@ -48,10 +47,6 @@ const form = reactive({
globalScore: 0,
componentsId: [] as number[],
})
function getErrorMessage(field: string): string | null {
return errors.value[field] || null
}
</script>
<template>
+2 -11
View File
@@ -1,5 +1,5 @@
<script setup lang="ts">
import { computed, reactive } from 'vue'
import { reactive } from 'vue'
import { Link } from '@adonisjs/inertia/vue'
import { router, usePage } from '@inertiajs/vue3'
@@ -9,8 +9,7 @@ const { props } = usePage<{
states: any[]
errors?: Record<string, string>
}>()
const { computer, availableComponents, states } = props
const errors = computed(() => props.errors || {})
const { computer, states } = props
const form = reactive({
id: computer.id,
@@ -23,17 +22,9 @@ const form = reactive({
componentsId: computer.components.map((c: any) => c.id),
})
function updateComponents(componentsId: number[]) {
form.componentsId = componentsId
}
function deleteComputer(id: number) {
router.delete(`/computers/${id}`)
}
function getErrorMessage(field: string): string | null {
return errors.value[field] || null
}
</script>
<template>
+1 -1
View File
@@ -1,7 +1,7 @@
<script setup lang="ts">
import { Link } from '@adonisjs/inertia/vue'
const { props } = defineProps<{ computer: any }>()
const { computer } = defineProps<{ computer: any }>()
</script>
<template>