- Add IPC and runtime plumbing for preview annotation theming - Generate and ship annotation CSS for the desktop overlay - Add pointer and artifact handling for browser preview interactions
12 lines
464 B
TypeScript
12 lines
464 B
TypeScript
import type { PreviewSessionSnapshot, ProjectScript } from "@t3tools/contracts";
|
|
|
|
export function shouldShowPreviewEmptyState(snapshot: PreviewSessionSnapshot | null): boolean {
|
|
return snapshot === null || snapshot.navStatus._tag === "Idle";
|
|
}
|
|
|
|
export function getConfiguredPreviewUrls(
|
|
scripts: ReadonlyArray<ProjectScript> | undefined,
|
|
): ReadonlyArray<string> {
|
|
return scripts?.flatMap((script) => (script.previewUrl ? [script.previewUrl] : [])) ?? [];
|
|
}
|