From 66e32f2210f40be65a3072de4da37d3e7afe0340 Mon Sep 17 00:00:00 2001 From: Alec Gibson <12036746+alecgibson@users.noreply.github.com> Date: Wed, 17 Jul 2024 08:42:00 +0100 Subject: [PATCH] =?UTF-8?q?=F0=9F=8F=B7=EF=B8=8F=20Add=20type=20definition?= =?UTF-8?q?s?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- index.d.ts | 12 ++++++++++++ package.json | 5 +++-- 2 files changed, 15 insertions(+), 2 deletions(-) create mode 100644 index.d.ts diff --git a/index.d.ts b/index.d.ts new file mode 100644 index 0000000..2a7f460 --- /dev/null +++ b/index.d.ts @@ -0,0 +1,12 @@ +declare module '@reedsy/rich-text' { + export * as Delta from '@reedsy/quill-delta'; + import sharedb from 'sharedb'; + + export type Type = (typeof sharedb)['types']['map'][string]; + + export const config: { + serializedProperties: Record; + }; + + export const type: Type; +} diff --git a/package.json b/package.json index 270fa0e..acb74cb 100644 --- a/package.json +++ b/package.json @@ -1,12 +1,13 @@ { "name": "@reedsy/rich-text", - "version": "4.1.0-reedsy.4.0.0", + "version": "4.1.0-reedsy.4.1.0", "description": "OT type for rich text", "author": "Jason Chen ", "homepage": "https://github.com/ottypes/rich-text", "main": "index.js", "dependencies": { - "@reedsy/quill-delta": "^5.1.0-reedsy.3.0.0" + "@reedsy/quill-delta": "^5.1.0-reedsy.3.0.0", + "@types/sharedb": "^3.3.11" }, "devDependencies": { "chai": "^4.2.0",