For the complete documentation index, see llms.txt. This page is also available as Markdown.
react-native

UI Customizations

Customize Document Detector UI for React Native. Configure capture messages, preview, upload, retry screens, and document selection copy.

Certta Document Detector supports customizing in-flow messages, preview screens, upload dialogs, and retry copy. Pass customization objects on CerttaDocumentDetectorConfiguration or CerttaDocumentDetectorUIConfiguration when calling open().

Capture messages

await open({
  flow: [{ document: CafDocument.RG_FRONT }],
  messageCustomization: {
    title: 'Capture your document',
    subtitle: 'Fit the document inside the frame',
  },
});

Preview screen

await open({
  flow: [{ document: CafDocument.RG_FRONT }],
  showPreview: true,
  previewCustomization: {
    title: 'Review your photo',
    confirmButton: 'Use this photo',
    retakeButton: 'Take again',
  },
});

Upload mode

Retry screen

Document Detector UI — selection and instructions

Use useCafDocumentDetectorUI for the built-in picker and instruction screens:

For the full list of customization fields, see the TypeScript types CafDocumentDetectorMessageCustomization, CafDocumentDetectorPreviewCustomization, CafDocumentDetectorUploadCustomization, CafDocumentDetectorUploadMessagesCustomization, and CafDocumentDetectorRetryCustomization exported from @caf.io/react-native-sdk.

Atualizado