UNPKG

688 BTypeScriptView Raw
1import { Operation, Point } from '..';
2import { TextDirection } from '../types/types';
3/**
4 * `PointRef` objects keep a specific point in a document synced over time as new
5 * operations are applied to the editor. You can access their `current` property
6 * at any time for the up-to-date point value.
7 */
8export interface PointRef {
9 current: Point | null;
10 affinity: TextDirection | null;
11 unref(): Point | null;
12}
13export interface PointRefInterface {
14 /**
15 * Transform the point ref's current value by an operation.
16 */
17 transform: (ref: PointRef, op: Operation) => void;
18}
19export declare const PointRef: PointRefInterface;
20//# sourceMappingURL=point-ref.d.ts.map
\No newline at end of file