From 531a1eef9c27fc5b9cc8af1308b07dda40e96f2a Mon Sep 17 00:00:00 2001 From: Zihua Li Date: Thu, 23 May 2024 11:22:14 +0800 Subject: [PATCH] Export Delta, AttributeMap and other related objects (#4220) Co-authored-by: Zihua Li <635902+luin@users.noreply.github.com> --- packages/quill/src/quill.ts | 13 ++++++++++--- packages/quill/test/types/quill.test-d.ts | 3 +-- 2 files changed, 11 insertions(+), 5 deletions(-) diff --git a/packages/quill/src/quill.ts b/packages/quill/src/quill.ts index 648183434b..9ae4198430 100644 --- a/packages/quill/src/quill.ts +++ b/packages/quill/src/quill.ts @@ -1,4 +1,4 @@ -import Quill, { Parchment, Range } from './core.js'; +import Quill from './core.js'; import type { Bounds, DebugLevel, @@ -115,7 +115,15 @@ Quill.register( true, ); -export { Module } from './core.js'; +export { + AttributeMap, + Delta, + Module, + Op, + OpIterator, + Parchment, + Range, +} from './core.js'; export type { Bounds, DebugLevel, @@ -123,6 +131,5 @@ export type { ExpandedQuillOptions, QuillOptions, }; -export { Parchment, Range }; export default Quill; diff --git a/packages/quill/test/types/quill.test-d.ts b/packages/quill/test/types/quill.test-d.ts index 1a2ca74040..a46bc216d2 100644 --- a/packages/quill/test/types/quill.test-d.ts +++ b/packages/quill/test/types/quill.test-d.ts @@ -1,7 +1,6 @@ import { assertType, expectTypeOf } from 'vitest'; -import Quill from '../../src/quill.js'; +import Quill, { Delta } from '../../src/quill.js'; import type { EmitterSource, Parchment, Range } from '../../src/quill.js'; -import Delta from 'quill-delta'; import type { default as Block, BlockEmbed } from '../../src/blots/block.js'; import SnowTheme from '../../src/themes/snow.js'; import { LeafBlot } from 'parchment';