diff --git a/src/lib/utils/html.svelte.ts b/src/lib/utils/html.svelte.ts index ddf4574..2aca714 100644 --- a/src/lib/utils/html.svelte.ts +++ b/src/lib/utils/html.svelte.ts @@ -1,6 +1,6 @@ import type { Position } from './math'; -const _windowState = $state({ width: NaN, height: NaN }); +const _windowState = $state({ width: 1879, height: 961 }); let _isWindowStateSetup = false; /** * Reactive window state for use in svelte 5. diff --git a/src/lib/utils/html.test.ts b/src/lib/utils/html.test.ts index 115ed37..4e8fe5a 100644 --- a/src/lib/utils/html.test.ts +++ b/src/lib/utils/html.test.ts @@ -1,6 +1,5 @@ import { describe, expect, it } from 'vitest'; -import { Rect, WindowState, download, isBrowser } from './html.svelte'; -import { Window } from 'happy-dom'; +import { Rect, WindowState, isBrowser } from './html.svelte'; describe('WindowState', () => { it('should return the window width', () => { diff --git a/src/routes/html/+page.svelte b/src/routes/html/+page.svelte new file mode 100644 index 0000000..314cb08 --- /dev/null +++ b/src/routes/html/+page.svelte @@ -0,0 +1,14 @@ + + +