UNPKG

@veltdev/types

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.

37 lines (36 loc) 1.1 kB
import { PageInfo } from "./page-info.model"; import { TargetTextRange } from "./target-text-range.data.model"; import { User } from "./user.data.model"; export declare class Selection { /** * User focused on specific element or text */ user?: User; /** * Type of event through highlight event is fired */ type?: 'focus' | 'click' | 'selection'; /** * XPath of highlighted element */ targetElement?: string | null; /** * Selected text to highlight */ targetTextRange?: TargetTextRange | null; pageInfo: PageInfo; timestamp: number; } export declare const UserIndicatorPosition: { readonly Start: "start"; readonly End: "end"; }; export type UserIndicatorPosition = (typeof UserIndicatorPosition)[keyof typeof UserIndicatorPosition]; export declare const UserIndicatorType: { readonly Avatar: "avatar"; readonly Label: "label"; }; export type UserIndicatorType = (typeof UserIndicatorType)[keyof typeof UserIndicatorType]; export declare class LiveSelectionData { [userIdHash: string]: Selection; }