@yoopta/editor
Version:
<h2 align="center">Yoopta-Editor v1 🎉</h2> <p align="center">Yoopta-Editor - is an open source notion-like editor 💥</p> <div align="center"> <img width="574" alt="Screen Shot 2023-01-25 at 16 04 29" src="https://user-images.githubusercontent.com/2909311
24 lines • 805 B
TypeScript
import type { YooEditor } from '../types';
import type { SetSlateSelectionOptions } from './types';
/**
* Set Slate selection in block
*
* @param editor - YooEditor instance
* @param options - Set selection options
*
* @example
* ```typescript
* // Set selection in current block
* Selection.setSlateSelection(editor, {
* selection: { anchor: { path: [0, 0], offset: 0 }, focus: { path: [0, 0], offset: 5 } }
* });
*
* // Set selection in specific block
* Selection.setSlateSelection(editor, {
* selection: { anchor: { path: [0, 0], offset: 0 }, focus: { path: [0, 0], offset: 5 } },
* at: 0
* });
* ```
*/
export declare function setSlateSelection(editor: YooEditor, options: SetSlateSelectionOptions): void;
//# sourceMappingURL=setSlateSelection.d.ts.map