mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-02-25 02:13:00 +08:00
16 lines
444 B
TypeScript
16 lines
444 B
TypeScript
import { createIdentifier } from '@blocksuite/global/di';
|
|
import type { ExtensionType } from '@blocksuite/store';
|
|
import { Subject } from 'rxjs';
|
|
|
|
import type { Viewport } from '../types';
|
|
|
|
export const PageViewportService = createIdentifier<Subject<Viewport>>(
|
|
'PageViewportService'
|
|
);
|
|
|
|
export const PageViewportServiceExtension: ExtensionType = {
|
|
setup: di => {
|
|
di.addImpl(PageViewportService, () => new Subject<Viewport>());
|
|
},
|
|
};
|