Skip to content
Snippets Groups Projects
Code owners
Assign users and groups as approvers for specific file changes. Learn more.
commentSchema.ts 431 B
import { z } from 'zod';

const coordinatesSchema = z.object({
  x: z.number(),
  y: z.number(),
});

export const commentSchema = z.object({
  title: z.string(),
  icon: z.string(),
  type: z.enum(['POINT', 'ALIAS', 'REACTION']),
  content: z.string(),
  removed: z.boolean(),
  coord: coordinatesSchema,
  modelId: z.number(),
  elementId: z.string(),
  id: z.number(),
  pinned: z.boolean(),
  owner: z.string().optional(),
});