mirror of
https://github.com/ianstormtaylor/slate.git
synced 2025-08-19 13:41:19 +02:00
Fix TS type errors. (#4014)
Fix for https://github.com/ianstormtaylor/slate/issues/4003
This commit is contained in:
@@ -83,6 +83,7 @@ export interface EditorInterface {
|
||||
options?: {
|
||||
distance?: number
|
||||
unit?: 'offset' | 'character' | 'word' | 'line' | 'block'
|
||||
voids?: boolean
|
||||
}
|
||||
) => Point | undefined
|
||||
before: (
|
||||
@@ -91,6 +92,7 @@ export interface EditorInterface {
|
||||
options?: {
|
||||
distance?: number
|
||||
unit?: 'offset' | 'character' | 'word' | 'line' | 'block'
|
||||
voids?: boolean
|
||||
}
|
||||
) => Point | undefined
|
||||
deleteBackward: (
|
||||
@@ -246,7 +248,13 @@ export interface EditorInterface {
|
||||
rangeRefs: (editor: Editor) => Set<RangeRef>
|
||||
removeMark: (editor: Editor, key: string) => void
|
||||
start: (editor: Editor, at: Location) => Point
|
||||
string: (editor: Editor, at: Location) => string
|
||||
string: (
|
||||
editor: Editor,
|
||||
at: Location,
|
||||
options?: {
|
||||
voids?: boolean
|
||||
}
|
||||
) => string
|
||||
unhangRange: (
|
||||
editor: Editor,
|
||||
range: Range,
|
||||
|
@@ -17,6 +17,7 @@ export interface PathInterface {
|
||||
endsAt: (path: Path, another: Path) => boolean
|
||||
endsBefore: (path: Path, another: Path) => boolean
|
||||
equals: (path: Path, another: Path) => boolean
|
||||
hasPrevious: (path: Path) => boolean
|
||||
isAfter: (path: Path, another: Path) => boolean
|
||||
isAncestor: (path: Path, another: Path) => boolean
|
||||
isBefore: (path: Path, another: Path) => boolean
|
||||
|
Reference in New Issue
Block a user