mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-02-13 04:48:53 +00:00
fix(electron): window only ui (#2926)
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
import { migrateToSubdoc } from '@affine/env/blocksuite';
|
||||
import { setupGlobal } from '@affine/env/global';
|
||||
import { platformSchema, setupGlobal } from '@affine/env/global';
|
||||
import type {
|
||||
LocalIndexedDBDownloadProvider,
|
||||
WorkspaceAdapter,
|
||||
@@ -39,6 +39,13 @@ if (!environment.isServer) {
|
||||
import('@affine/bookmark-block');
|
||||
}
|
||||
|
||||
// platform check
|
||||
{
|
||||
if (globalThis.platform) {
|
||||
platformSchema.parse(globalThis.platform);
|
||||
}
|
||||
}
|
||||
|
||||
if (!environment.isDesktop && !environment.isServer) {
|
||||
// Polyfill Electron
|
||||
const unimplemented = () => {
|
||||
|
||||
Reference in New Issue
Block a user