chore: bump blocksuite (#1298)

Co-authored-by: Himself65 <himself65@outlook.com>
This commit is contained in:
Yifeng Wang
2023-03-04 04:17:06 +08:00
committed by GitHub
parent 50ff9b0c5c
commit 205092180b
14 changed files with 95 additions and 95 deletions

View File

@@ -14,11 +14,11 @@
"@affine/debug": "workspace:*",
"@affine/env": "workspace:*",
"@affine/i18n": "workspace:*",
"@blocksuite/blocks": "0.5.0-20230302205056-4385b7a",
"@blocksuite/editor": "0.5.0-20230302205056-4385b7a",
"@blocksuite/blocks": "0.5.0-20230303192351-13b0dd7",
"@blocksuite/editor": "0.5.0-20230303192351-13b0dd7",
"@blocksuite/icons": "2.0.17",
"@blocksuite/react": "0.5.0-20230302205056-4385b7a",
"@blocksuite/store": "0.5.0-20230302205056-4385b7a",
"@blocksuite/react": "0.5.0-20230303192351-13b0dd7",
"@blocksuite/store": "0.5.0-20230303192351-13b0dd7",
"@emotion/cache": "^11.10.5",
"@emotion/css": "^11.10.6",
"@emotion/react": "^11.10.6",

View File

@@ -41,7 +41,7 @@ beforeEach(async () => {
})
.register(builtInSchemas)
.register(__unstableSchemas);
blockSuiteWorkspace.signals.pageAdded.on(pageId => {
blockSuiteWorkspace.slots.pageAdded.on(pageId => {
setTimeout(() => {
const page = blockSuiteWorkspace.getPage(pageId);
expect(page).not.toBeNull();

View File

@@ -22,7 +22,7 @@ beforeEach(() => {
})
.register(builtInSchemas)
.register(__unstableSchemas);
blockSuiteWorkspace.signals.pageAdded.on(pageId => {
blockSuiteWorkspace.slots.pageAdded.on(pageId => {
const page = blockSuiteWorkspace.getPage(pageId) as Page;
const pageBlockId = page.addBlockByFlavour('affine:page', { title: '' });
const frameId = page.addBlockByFlavour('affine:frame', {}, pageBlockId);

View File

@@ -11,7 +11,7 @@ export function useBlockSuiteWorkspaceHelper(
createPage: (pageId: string, title?: string): Promise<string> => {
return new Promise(resolve => {
assertExists(blockSuiteWorkspace);
const dispose = blockSuiteWorkspace.signals.pageAdded.on(id => {
const dispose = blockSuiteWorkspace.slots.pageAdded.on(id => {
if (id === pageId) {
dispose.dispose();
// Fixme: https://github.com/toeverything/blocksuite/issues/1350

View File

@@ -33,7 +33,7 @@ const PreviewPage: NextPage<PreviewPageProps> = ({
'preview',
(_: string) => undefined
);
blockSuiteWorkspace.signals.pageAdded.once(() => {
blockSuiteWorkspace.slots.pageAdded.once(() => {
setBlockSuiteWorkspace(blockSuiteWorkspace);
});
blockSuiteWorkspace.createPage('preview');

View File

@@ -30,7 +30,7 @@ const WorkspaceDetail: React.FC = () => {
const [, rerender] = useState(false);
// fixme(himself65): this is a hack
useEffect(() => {
const dispose = currentWorkspace?.blockSuiteWorkspace.signals.pageAdded.on(
const dispose = currentWorkspace?.blockSuiteWorkspace.slots.pageAdded.on(
id => {
if (pageId === id) {
rerender(prev => !prev);
@@ -40,7 +40,7 @@ const WorkspaceDetail: React.FC = () => {
return () => {
dispose?.dispose();
};
}, [currentWorkspace?.blockSuiteWorkspace.signals.pageAdded, pageId]);
}, [currentWorkspace?.blockSuiteWorkspace.slots.pageAdded, pageId]);
useEffect(() => {
if (currentWorkspace) {
enableFullFlags(currentWorkspace.blockSuiteWorkspace);