From 20a70fad2a943ea5ae43c1e37a52c758c5df0bab Mon Sep 17 00:00:00 2001 From: Ivan Malison Date: Sat, 11 Jul 2026 20:55:53 -0700 Subject: [PATCH] Allow transient homography IDs --- src/index.tsx | 25 +++++++++++++++++++------ src/schema.gql | 10 +++++++++- 2 files changed, 28 insertions(+), 7 deletions(-) diff --git a/src/index.tsx b/src/index.tsx index cac063d..0b0bd04 100644 --- a/src/index.tsx +++ b/src/index.tsx @@ -2400,7 +2400,7 @@ export type HomographyInfoGql = { crop: BoundingBoxGql; destPoints: PocketPointsGql; frameIndex: Scalars["Int"]["output"]; - id: Scalars["Int"]["output"]; + id?: Maybe; pockets: Array; sourcePoints: PocketPointsGql; }; @@ -3080,6 +3080,7 @@ export type Query = { getResolvedTier: ResolvedTierGql; getRuns: GetRunsResult; getShotAnnotationTypes: Array; + getShotTableState: ShotTableStateGql; getShots: Array; getShotsByIds: Array; getShotsWithMetadata: GetShotsResult; @@ -3225,6 +3226,10 @@ export type QueryGetShotAnnotationTypesArgs = { errorTypes?: InputMaybe; }; +export type QueryGetShotTableStateArgs = { + shotId: Scalars["Int"]["input"]; +}; + export type QueryGetShotsArgs = { countRespectsLimit?: Scalars["Boolean"]["input"]; filterInput: FilterInput; @@ -3604,6 +3609,14 @@ export type ShotProjectionGql = { trajectories: Array; }; +export type ShotTableStateGql = { + __typename?: "ShotTableStateGQL"; + frameIndex: Scalars["Int"]["output"]; + shotId: Scalars["Int"]["output"]; + tableState: TableStateGql; + videoId: Scalars["Int"]["output"]; +}; + export type ShotsOrderingComponent = | { difficulty: FloatOrdering; @@ -6826,7 +6839,7 @@ export type GetLiveTableStateQuery = { } | null>; homography?: { __typename?: "HomographyInfoGQL"; - id: number; + id?: number | null; frameIndex: number; crop: { __typename?: "BoundingBoxGQL"; @@ -7855,7 +7868,7 @@ export type GetStreamMonitoringDetailsQuery = { elapsedTime?: number | null; currentHomography?: { __typename?: "HomographyInfoGQL"; - id: number; + id?: number | null; frameIndex: number; crop: { __typename?: "BoundingBoxGQL"; @@ -8269,7 +8282,7 @@ export type GetVideoQuery = { } | null; homographyHistory: Array<{ __typename?: "HomographyInfoGQL"; - id: number; + id?: number | null; frameIndex: number; crop: { __typename?: "BoundingBoxGQL"; @@ -8517,7 +8530,7 @@ export type FindPrerecordTableLayoutMutation = { __typename?: "Mutation"; findPrerecordTableLayout?: { __typename?: "HomographyInfoGQL"; - id: number; + id?: number | null; frameIndex: number; crop: { __typename?: "BoundingBoxGQL"; @@ -8547,7 +8560,7 @@ export type FindPrerecordTableLayoutMutation = { export type HomographyInfoFragment = { __typename?: "HomographyInfoGQL"; - id: number; + id?: number | null; frameIndex: number; crop: { __typename?: "BoundingBoxGQL"; diff --git a/src/schema.gql b/src/schema.gql index 5c0b37f..1056fa1 100644 --- a/src/schema.gql +++ b/src/schema.gql @@ -73,6 +73,7 @@ type Query { useHomography: HomographyInputGQL = null ): TableStateGQL! getLiveTableState(videoId: Int!): LiveTableStateGQL! + getShotTableState(shotId: Int!): ShotTableStateGQL! simulateShot(simulationInput: SimulateShotInputGQL!): ShotProjectionGQL! computePotAim( simulationInput: SimulateShotInputGQL! @@ -609,7 +610,7 @@ type VideoTagClass { } type HomographyInfoGQL { - id: Int! + id: Int frameIndex: Int! crop: BoundingBoxGQL! pockets: [BoundingBoxGQL!]! @@ -1065,6 +1066,13 @@ type LiveTableStateGQL { tableState: TableStateGQL! } +type ShotTableStateGQL { + shotId: Int! + videoId: Int! + frameIndex: Int! + tableState: TableStateGQL! +} + type ShotProjectionGQL { trajectories: [BallTrajectoryGQL!]! events: [SimulationEventGQL!]!