feat: full studio build -- light theme, canvas thumbnails, i18n (fa/en)

This commit is contained in:
Soroush.Asadi
2026-05-24 17:37:21 +03:30
parent d962483359
commit c61f587767
295 changed files with 29797 additions and 265 deletions
+21
View File
@@ -0,0 +1,21 @@
import { getStudioStage } from "@/lib/studio-canvas-stage";
/** Wait for Konva to paint after store-driven layer changes */
export function scheduleSceneThumbnailCapture(
capture: () => void
): void {
requestAnimationFrame(() => {
requestAnimationFrame(capture);
});
}
export function captureSceneThumbnailFromStage(): string | null {
const stage = getStudioStage();
if (!stage) return null;
try {
return stage.toDataURL({ pixelRatio: 0.2 });
} catch {
return null;
}
}