Allow dot notation access of known DeltaOperation properties

This commit is contained in:
icosahebron
2017-06-16 22:12:41 -07:00
parent 174f07f383
commit e9c2d11fb2
+1 -1
View File
@@ -16,7 +16,7 @@ declare namespace Quill {
*
* But this would break a lot of existing code as it would require manual discrimination of the union types.
*/
type DeltaOperation = StringMap & OptionalAttributes;
type DeltaOperation = { insert?: any, delete?: number, retain?: number } & OptionalAttributes;
type TextChangeHandler = (delta: DeltaStatic, oldContents: DeltaStatic, source: Sources) => any;
type SelectionChangeHandler = (range: RangeStatic, oldRange: RangeStatic, source: Sources) => any;