Fix SSR and automerge timing

SSR fix:
- ClientOnly wrapper prevents Leaflet/Yjs from running during SSR
- SessionView lazy-loaded to avoid browser API usage on server

Automerge fix:
- Set MERGE_READY_STATE to 'clean' only (was including 'unstable')
- Prevents merging before all CI checks complete

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
Ullrich Schäfer 2026-03-23 00:49:54 +01:00
parent e0cce17b8d
commit e40b7dc199
No known key found for this signature in database
GPG key ID: A32FF691A0F752D9
4 changed files with 96 additions and 45 deletions

View file

@ -0,0 +1,17 @@
import { useState, useEffect, type ReactNode } from "react";
export function ClientOnly({
children,
fallback = null,
}: {
children: () => ReactNode;
fallback?: ReactNode;
}) {
const [mounted, setMounted] = useState(false);
useEffect(() => {
setMounted(true);
}, []);
return mounted ? <>{children()}</> : <>{fallback}</>;
}