@veltdev/sdk
Version:
Velt is an SDK to add collaborative features to your product within minutes. Example: Comments like Figma, Frame.io, Google docs or sheets, Recording like Loom, Huddles like Slack and much more.
74 lines (62 loc) • 1.97 kB
TypeScript
// @ts-nocheck
import { Observable } from "rxjs";
import { PresenceUser } from "../data/presence-user.data.model";
export declare class PresenceElement {
/**
* Subscribe to a list of all online users who are either active or inactive on the current document.
*
* Returns Observable<PresenceUser[] | null>.
*/
getOnlineUsersOnCurrentDocument: () => Observable<PresenceUser[] | null>;
/**
* To set inactivity time (Default value is 5 minutes)
* @param time inactivity time in milliseconds
*/
setInactivityTime: (time: number) => void;
/**
* Enables follow along mode globally
* @param options {FollowOptions: {useHistoryAPI: boolean, onNavigate: (url: PageInfo) => void}}}
*/
enableFollowAlongMode: (useHistoryAPI: boolean) => any;
/**
* To disable follow along mode
*/
disableFollowAlongMode: () => any;
/**
* To enable adding self to the presence list
*/
enableSelf: () => void;
/**
* To disable adding self to the presence list
*/
disableSelf: () => void;
constructor();
/**
* Subscribe to a list of all online users who are either active or inactive on the current document.
*
* Returns Observable<PresenceUser[] | null>.
*/
private _getOnlineUsersOnCurrentDocument;
/**
* To set inactivity time (Default value is 5 minutes)
* @param time inactivity time in milliseconds
*/
private _setInactivityTime;
/**
* Enables follow along mode globally
* @param options {FollowOptions: {useHistoryAPI: boolean, onNavigate: (url: PageInfo) => void}}}
*/
private _enableFollowAlongMode;
/**
* To disable follow along mode
*/
private _disableFollowAlongMode;
/**
* To enable adding self to the presence list
*/
private _enableSelf;
/**
* To disable adding self to the presence list
*/
private _disableSelf;
}