Skip to main content

Libraries

  • @veltdev/react
  • @veltdev/client
  • @veltdev/sdk
5.0.0-beta.7
January 28, 2026

New Features

  • [Comments]: Added addCommentAnnotationDraft event to dynamically set context when creating comment annotations. Triggered before addCommentAnnotation event clicks on the comment tool and the composer is rendered.
// Using hook
const addCommentAnnotationDraftEvent = useCommentEventCallback('addCommentAnnotationDraft');

useEffect(() => {
    if (addCommentAnnotationDraftEvent?.addContext) {
        addCommentAnnotationDraftEvent.addContext({
            questionId: '123',
            questionText: 'What is the capital of France?',
        });
    }
}, [addCommentAnnotationDraftEvent]);

// Using API method
const client = useVeltClient();
const commentElement = client.getCommentElement();
commentElement.on('addCommentAnnotationDraft').subscribe((event) => {
    if (event?.addContext) {
        event.addContext({
            questionId: '123',
            questionText: 'What is the capital of France?',
        });
    }
});

Improvements

  • [Comments]: Added setContextProvider method to set a global context provider for all comment annotations. Also added useSetContextProvider hook for React applications.
// Using hook
import { useCallback, useEffect } from 'react';
import { useSetContextProvider } from '@veltdev/react';

const contextProvider = useCallback((documentId, location) => {
    return {
        questionId: '123',
        questionText: 'What is the capital of France?',
    }
}, []);

const { setContextProvider } = useSetContextProvider();

useEffect(() => {
    if (setContextProvider && contextProvider) {
        setContextProvider(contextProvider);
    }
}, []);

// Using API method
const client = useVeltClient();
const commentElement = client.getCommentElement();
commentElement.setContextProvider((documentId, location) => {
    return {
        questionId: '123',
        questionText: 'What is the capital of France?',
    }
});
5.0.0-beta.6
January 28, 2026

Bug Fixes

  • [Core]: Fixed package integrity issue in v5.0.0-beta.5.
5.0.0-beta.5
January 28, 2026

Bug Fixes

  • [Comments]: Fixed page mode and multi-thread annotation ID not found error. Page mode and multi-thread comments now work as expected.
  • [Comments]: Fixed updateOverlayPosition function not triggering. Comment dialog now opens in the correct position.
  • [Comments]: Fixed unread status issues in inline and focused thread modes. Annotations are now marked as read when opened or clicked.
  • [Comments]: Fixed three-dot menu not visible in sidebar.
  • [Comments]: Fixed composer not being focused when opened.
  • [Comments]: Fixed comments navigating on click. Comments now only navigate when the navigation button is clicked.
5.0.0-beta.4
January 23, 2026

Bug Fixes

  • [Comments]: Fixed lastUpdated timestamp not being updated when changing context in comment annotation via SDK. Ensures context updates are properly synced to other users.
5.0.0-beta.3
January 22, 2026

Improvements

  • [Core]: Added robustness to initialization when VeltProvider was re-rendered multiple times over a slow network.

Bug Fixes

  • [Comments]: Refactored submitComment method to fix resolver issue for velt-comment-composer. Now follows the standard comment submission flow.
  • [Comments]: Fixed unread status not updating correctly in bottom sheet. This was a regression in v5.
  • [Comments]: Fixed navigation button not working properly. This was a regression in v5.
  • [Comments]: Fixed disable recording option not working in velt-comment-composer. This was a regression in v5.
5.0.0-beta.2
January 22, 2026

New Features

  • [Core]: Added globalStyles option to control whether Velt’s global CSS is loaded. Set to false to disable default styles when implementing custom theming.
// Using VeltProvider
<VeltProvider apiKey='API_KEY' config={{
    globalStyles: false
}}>
    {/* Your app content */}
</VeltProvider>

// Using API method
const client = useVeltClient();
client.initConfig('API_KEY', {
  globalStyles: false
});
  • [Comments]: Added submitComment(targetElementId) method to programmatically trigger comment submission. Enables custom buttons or keyboard shortcuts for submitting comments. Learn more

<VeltCommentComposer targetElementId="composer-1" />
<VeltCommentDialogComposer targetElementId="composer-2" />

// Using hook
const commentElement = useCommentUtils();
commentElement.submitComment('composer-1');

// Using API method
const client = useVeltClient();
const commentElement = client.getCommentElement();
commentElement.submitComment('composer-1');
  • [Comments]: Added placeholder prop to customize input placeholder text in comment composer. Overrides default placeholders. Learn more
<VeltCommentComposer placeholder="Share your thoughts..." />
<VeltCommentDialogComposer placeholder="Add a comment..." />
  • [Comments]: Added composerTextChange event that fires when text changes in any comment composer. Enables features like auto-save drafts, character counters, or real-time validation. Learn more
// Using hook
const composerTextChangeEvent = useCommentEventCallback('composerTextChange');
useEffect(() => {
    if (composerTextChangeEvent) {
        console.log('Text changed:', composerTextChangeEvent.text);
    }
}, [composerTextChangeEvent]);

// Using API method
const client = useVeltClient();
const commentElement = client.getCommentElement();
commentElement.on('composerTextChange').subscribe((event) => {
    console.log('Text changed:', event.text);
});
5.0.0-beta.1
January 21, 2026

Bug Fixes

Comment Dialog Primitives

Released 115+ primitive components for building custom comment dialogs. Each subcomponent can now be used independently without requiring the full dialog structure.
// Pattern 1: ID-Based (Standalone)
<VeltCommentDialogHeader annotationId="abc123" />
<VeltCommentDialogComposer annotationId="abc123" />

// Pattern 2: Context Wrapper
<VeltCommentDialogContextWrapper annotationId="abc123">
  <VeltCommentDialogHeader />
  <VeltCommentDialogComposer />
  <VeltCommentDialogBody />
</VeltCommentDialogContextWrapper>
Available Components:
  • Header/Body: Header, Body, CloseButton
  • Thread: ThreadCard with Avatar, Name, Time, Message, Reactions, Recordings, Reply, Options, and more
  • Composer: Composer, ComposerInput, ComposerActionButton, ComposerAttachmentButton, ComposerRecorderButton, ComposerRecorderPlayer, ComposerFiles
  • Dropdowns: StatusDropdown, PriorityDropdown, OptionsDropdown, CustomAnnotationDropdown (each with full sub-component breakdown)
  • Additional: ReplyAvatars, AssigneeBanner, ResolveButton, UnresolveButton, CopyLink, DeleteButton, PrivateBanner, NavigationButton, and 90+ more
View full documentation → | API Methods | Data Models