2024-10-13 15:25:30 -07:00
|
|
|
import * as v from 'valibot';
|
2024-08-28 11:58:20 -07:00
|
|
|
|
2024-10-13 15:25:30 -07:00
|
|
|
const pleromaConfigSchema = v.object({
|
|
|
|
configs: z.array(v.object({
|
2024-08-28 11:58:20 -07:00
|
|
|
value: z.any(),
|
2024-10-13 15:25:30 -07:00
|
|
|
group: v.string(),
|
|
|
|
key: v.string(),
|
2024-08-28 11:58:20 -07:00
|
|
|
})),
|
2024-10-13 15:25:30 -07:00
|
|
|
need_reboot: v.boolean(),
|
2024-08-28 11:58:20 -07:00
|
|
|
});
|
|
|
|
|
2024-10-13 15:25:30 -07:00
|
|
|
type PleromaConfig = v.InferOutput<typeof pleromaConfigSchema>
|
2024-08-28 11:58:20 -07:00
|
|
|
|
|
|
|
export { pleromaConfigSchema, type PleromaConfig };
|