refactor: remove pocketbase (#1138)

This commit is contained in:
Jonas Plum
2025-09-02 21:58:08 +02:00
committed by GitHub
parent f28c238135
commit eba2615ec0
435 changed files with 42677 additions and 4730 deletions

View File

@@ -14,7 +14,19 @@ import {
import isEqual from 'lodash.isequal'
import { onMounted, ref, watch } from 'vue'
import type { JSONSchema } from '@/lib/types'
interface JSONSchema {
type: 'object'
properties: Record<
string,
{
title: string
type: string
description?: string
enum?: Array<string>
}
>
required?: Array<string>
}
const model = defineModel<Record<string, any>>()
@@ -27,7 +39,7 @@ const formdata = ref<Record<string, any>>({})
onMounted(() => {
if (!model.value) return
for (const key in props.schema.properties) {
for (const key in props.schema?.properties) {
formdata.value[key] = model.value[key]
}
})
@@ -47,7 +59,7 @@ watch(
</script>
<template>
<div v-for="(property, key) in schema.properties" :key="key">
<div v-for="(property, key) in schema?.properties" :key="key">
<FormField v-if="property.enum" :name="key" v-slot="{ componentField }" v-model="formdata[key]">
<FormItem>
<FormLabel :for="key" class="text-right">