mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-07-17 18:16:15 +08:00
d6ab958e15
Closes: BS-3202 <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - **New Features** - Introduced new root block store and view extensions, enhancing modularity and integration options for root block functionality. - Exported the EdgelessLocker class for broader usage. - **Improvements** - Updated export paths for root block modules, enabling clearer and more flexible module access. - Enhanced view extension setup to better tailor user interface and interactions based on context. - **Removals** - Removed legacy migrating store and view extension logic, streamlining extension management and reducing unused code. - Removed multiple deprecated block specifications and common extension collections to simplify the codebase. - Deleted AI page root block specification, retaining only lifecycle watcher functionality. - **Chores** - Updated dependencies and project references to support new extension loader integration. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
18 lines
529 B
TypeScript
18 lines
529 B
TypeScript
import {
|
|
type StoreExtensionContext,
|
|
StoreExtensionProvider,
|
|
} from '@blocksuite/affine-ext-loader';
|
|
import { RootBlockSchemaExtension } from '@blocksuite/affine-model';
|
|
|
|
import { RootBlockAdapterExtensions } from './adapters/extension';
|
|
|
|
export class RootStoreExtension extends StoreExtensionProvider {
|
|
override name = 'affine-root-block';
|
|
|
|
override setup(context: StoreExtensionContext) {
|
|
super.setup(context);
|
|
context.register(RootBlockSchemaExtension);
|
|
context.register(RootBlockAdapterExtensions);
|
|
}
|
|
}
|