Merge pull request #11153 from sumitkm/master

Updated pasteHTML(...) interface definitions and bumped version to v1.0.3
This commit is contained in:
Sheetal Nandi
2016-09-09 15:54:46 -07:00
committed by GitHub
2 changed files with 15 additions and 2 deletions

View File

@@ -172,3 +172,15 @@ function test_on_EventType1(){
});
}
function test_PasteHTML()
{
var quillEditor = new Quill('#editor');
quillEditor.pasteHTML('<h1>Quill Rocks</h1>');
}
function test_PasteHTML2()
{
var quillEditor = new Quill('#editor');
quillEditor.pasteHTML(5, '<h1>Quill Rocks</h1>');
}

5
quill/quill.d.ts vendored
View File

@@ -1,4 +1,4 @@
// Type definitions for Quill v1.0.0
// Type definitions for Quill v1.0.3
// Project: http://quilljs.com
// Definitions by: Sumit <https://github.com/sumitkm>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
@@ -49,7 +49,8 @@ declare namespace QuillJS {
insertText(index: number, text: string, source?: sourceType): void;
insertText(index: number, text: string, format: string, value: string, source?: sourceType): void;
insertText(index: number, text: string, formats: formatsType, source?: sourceType): void;
pasteHTML(): string;
pasteHTML(index: number, html: string, source?:sourceType): string;
pasteHTML(html:string, source?: sourceType): string;
setContents(delta: DeltaStatic, source?: sourceType): void;
setText(text: string, source?: sourceType): void;
update(source?: string): void;