From 42c943f904c2844def690853446651596ca9a70f Mon Sep 17 00:00:00 2001
From: lawvs <18554747+lawvs@users.noreply.github.com>
Date: Thu, 4 Aug 2022 16:25:04 +0800
Subject: [PATCH] chore: clean code
---
.../editor-core/src/recast-block/README.md | 19 -------------------
.../editor-core/src/recast-block/group.ts | 4 ++--
2 files changed, 2 insertions(+), 21 deletions(-)
diff --git a/libs/components/editor-core/src/recast-block/README.md b/libs/components/editor-core/src/recast-block/README.md
index 59aed91be7..489412eab3 100644
--- a/libs/components/editor-core/src/recast-block/README.md
+++ b/libs/components/editor-core/src/recast-block/README.md
@@ -49,22 +49,3 @@ const SomeBlock = () => {
return
...
;
};
```
-
-## Scene
-
-**Notice: The scene API will refactor at next version.**
-
-```tsx
-const SomeBlock = () => {
- const { scene, setScene, setPage, setTable, setKanban } =
- useRecastBlockScene();
-
- return (
- <>
- Scene: {scene}
-
-
- >
- );
-};
-```
diff --git a/libs/components/editor-core/src/recast-block/group.ts b/libs/components/editor-core/src/recast-block/group.ts
index b8b25cce01..1b79612754 100644
--- a/libs/components/editor-core/src/recast-block/group.ts
+++ b/libs/components/editor-core/src/recast-block/group.ts
@@ -32,7 +32,7 @@ export const mergeGroup = async (...groups: AsyncBlock[]) => {
);
}
- await mergeGroupProperties(...(groups as RecastBlock[]));
+ await mergeGroupProperties(...(groups as unknown as RecastBlock[]));
const [headGroup, ...restGroups] = groups;
// Add all children to the head group
@@ -174,7 +174,7 @@ export const splitGroup = async (
}
splitGroupProperties(
- group as RecastBlock,
+ group as unknown as RecastBlock,
newGroupBlock as unknown as RecastBlock
);
await group.after(newGroupBlock);