mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-02-12 12:28:42 +00:00
@@ -1,19 +1,11 @@
|
||||
import './setup';
|
||||
|
||||
import { apis, events } from '@affine/electron-api';
|
||||
import { createI18n, setUpLanguage } from '@affine/i18n';
|
||||
import { StrictMode } from 'react';
|
||||
import { createRoot } from 'react-dom/client';
|
||||
|
||||
import { App } from './app';
|
||||
|
||||
function loadLanguage() {
|
||||
const i18n = createI18n();
|
||||
document.documentElement.lang = i18n.language;
|
||||
|
||||
setUpLanguage(i18n).catch(console.error);
|
||||
}
|
||||
|
||||
async function main() {
|
||||
const handleMaximized = (maximized: boolean | undefined) => {
|
||||
document.documentElement.dataset.maximized = String(maximized);
|
||||
@@ -31,7 +23,6 @@ async function main() {
|
||||
events?.ui.onFullScreen(handleFullscreen);
|
||||
events?.ui.onTabShellViewActiveChange(handleActive);
|
||||
|
||||
loadLanguage();
|
||||
mountApp();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user