feat(platform): harden access scoping and delivery baseline

This commit is contained in:
2026-03-30 00:27:31 +02:00
parent 00b936fa1f
commit 819345acfa
109 changed files with 26142 additions and 8081 deletions
+2 -2
View File
@@ -18,11 +18,11 @@ type ProjectDragContextResult = {
project: any | null;
};
export function useProjectDragContext(projectId: string | null): ProjectDragContextResult {
export function useProjectDragContext(projectId: string | null, enabled = true): ProjectDragContextResult {
// eslint-disable-next-line @typescript-eslint/no-explicit-any
const { data } = trpc.timeline.getProjectContext.useQuery(
{ projectId: projectId! },
{ enabled: !!projectId, staleTime: 10_000 },
{ enabled: enabled && !!projectId, staleTime: 10_000 },
) as { data: any };
return {