feat: async renderScene
This commit is contained in:
parent
f2611f5d1f
commit
9e9f564ea9
File diff suppressed because it is too large
Load Diff
@ -54,7 +54,7 @@ export const exportToCanvas = async (
|
|||||||
|
|
||||||
const onlyExportingSingleFrame = isOnlyExportingSingleFrame(elements);
|
const onlyExportingSingleFrame = isOnlyExportingSingleFrame(elements);
|
||||||
|
|
||||||
renderScene({
|
await renderScene({
|
||||||
elements,
|
elements,
|
||||||
appState,
|
appState,
|
||||||
scale,
|
scale,
|
||||||
|
@ -27,7 +27,7 @@ export type RenderConfig = {
|
|||||||
/** when exporting the behavior is slightly different (e.g. we can't use
|
/** when exporting the behavior is slightly different (e.g. we can't use
|
||||||
CSS filters), and we disable render optimizations for best output */
|
CSS filters), and we disable render optimizations for best output */
|
||||||
isExporting: boolean;
|
isExporting: boolean;
|
||||||
exportBackgroundImage?: string;
|
exportBackgroundImage?: string | null;
|
||||||
selectionColor?: string;
|
selectionColor?: string;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -54,3 +54,5 @@ export type Assert<T extends true> = T;
|
|||||||
export type NestedKeyOf<T, K = keyof T> = K extends keyof T & (string | number)
|
export type NestedKeyOf<T, K = keyof T> = K extends keyof T & (string | number)
|
||||||
? `${K}` | (T[K] extends object ? `${K}.${NestedKeyOf<T[K]>}` : never)
|
? `${K}` | (T[K] extends object ? `${K}.${NestedKeyOf<T[K]>}` : never)
|
||||||
: never;
|
: never;
|
||||||
|
|
||||||
|
export type Unpromisify<T> = T extends Promise<infer U> ? U : T;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user