mirror of
https://github.com/documenso/documenso.git
synced 2025-11-14 00:32:43 +10:00
feat: document authoring
This commit is contained in:
9
packages/prisma/guards/is-signature-field.ts
Normal file
9
packages/prisma/guards/is-signature-field.ts
Normal file
@ -0,0 +1,9 @@
|
||||
import { FieldType } from '@prisma/client';
|
||||
|
||||
const SignatureFieldTypes = [FieldType.SIGNATURE, FieldType.FREE_SIGNATURE] as const;
|
||||
|
||||
type SignatureFieldType = (typeof SignatureFieldTypes)[number];
|
||||
|
||||
export const isSignatureFieldType = (type: FieldType): type is SignatureFieldType => {
|
||||
return type === FieldType.SIGNATURE || type === FieldType.FREE_SIGNATURE;
|
||||
};
|
||||
Reference in New Issue
Block a user