feat: boot-экран, стабильность Windows и оптимизация Pixi/пульта
- Экран загрузки (boot.html, bootWindow): статусы, ensureRoots и проверка лицензии, редактор после готовности; закрытие через destroy при closable:false. - Упакованное приложение на Windows: disableHardwareAcceleration, sandbox выкл. вне dev, отложенный показ редактора, ensureWindowBecomesVisible, фокус на splash при second-instance. - Vite: вход boot.html; eslint: игнор release/; тесты boot и maxFPS тикера. - Пульт: позиция курсора кисти через ref/DOM без setState на каждый move; черновик эффекта через rAF; Pixi: maxFPS 32, resolution cap, antialias off, debounce ResizeObserver, меньше частиц poisonCloud, contain на хосте. Made-with: Cursor
This commit is contained in:
@@ -0,0 +1,28 @@
|
||||
import assert from 'node:assert/strict';
|
||||
import fs from 'node:fs';
|
||||
import path from 'node:path';
|
||||
import test from 'node:test';
|
||||
import { fileURLToPath } from 'node:url';
|
||||
|
||||
const here = path.dirname(fileURLToPath(import.meta.url));
|
||||
|
||||
function readBootWindow(): string {
|
||||
return fs.readFileSync(path.join(here, 'bootWindow.ts'), 'utf8');
|
||||
}
|
||||
|
||||
void test('bootWindow: экран загрузки без preload, статус из main', () => {
|
||||
const src = readBootWindow();
|
||||
assert.ok(src.includes('createBootWindow'));
|
||||
assert.ok(src.includes('destroyBootWindow'));
|
||||
assert.ok(src.includes('setBootWindowStatus'));
|
||||
assert.ok(src.includes('waitForBootWindowReady'));
|
||||
assert.ok(src.includes('executeJavaScript'));
|
||||
});
|
||||
|
||||
void test('createWindows: отложенный показ редактора для boot', () => {
|
||||
const src = fs.readFileSync(path.join(here, 'createWindows.ts'), 'utf8');
|
||||
assert.ok(src.includes('deferVisibility'));
|
||||
assert.ok(src.includes('createEditorWindowDeferred'));
|
||||
assert.ok(src.includes('waitForEditorWindowReady'));
|
||||
assert.ok(src.includes('getBootSplashWindow'));
|
||||
});
|
||||
Reference in New Issue
Block a user