mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-08-07 20:31:33 +08:00
refactor(editor): remove block models global type (#10086)
This commit is contained in:
@@ -1,8 +1,12 @@
|
||||
import type { BlockComponent, Command } from '@blocksuite/block-std';
|
||||
import type {
|
||||
BlockComponent,
|
||||
BlockStdScope,
|
||||
Command,
|
||||
} from '@blocksuite/block-std';
|
||||
|
||||
import { getNextContentBlock } from '../../utils/index.js';
|
||||
|
||||
function getNextBlock(std: BlockSuite.Std, path: string) {
|
||||
function getNextBlock(std: BlockStdScope, path: string) {
|
||||
const view = std.view;
|
||||
const model = std.store.getBlock(path)?.model;
|
||||
if (!model) return null;
|
||||
|
||||
@@ -1,8 +1,12 @@
|
||||
import type { BlockComponent, Command } from '@blocksuite/block-std';
|
||||
import type {
|
||||
BlockComponent,
|
||||
BlockStdScope,
|
||||
Command,
|
||||
} from '@blocksuite/block-std';
|
||||
|
||||
import { getPrevContentBlock } from '../../utils/index.js';
|
||||
|
||||
function getPrevBlock(std: BlockSuite.Std, path: string) {
|
||||
function getPrevBlock(std: BlockStdScope, path: string) {
|
||||
const view = std.view;
|
||||
|
||||
const model = std.store.getBlock(path)?.model;
|
||||
|
||||
Reference in New Issue
Block a user