diff --git a/codegen.yml b/codegen.yml index 34dbb6b..4d2f409 100644 --- a/codegen.yml +++ b/codegen.yml @@ -1,5 +1,7 @@ overwrite: true -schema: "src/schema.gql" +schema: + - "src/schema.gql" + - "src/client-schema.gql" documents: "src/**/*.gql" generates: src/index.tsx: diff --git a/src/client-schema.gql b/src/client-schema.gql new file mode 100644 index 0000000..31abcfa --- /dev/null +++ b/src/client-schema.gql @@ -0,0 +1,7 @@ +# see: https://www.apollographql.com/docs/react/local-state/managing-state-with-field-policies/ +directive @client on FIELD + +extend type ShotGQL { + startTime: Float! + endTime: Float! +} diff --git a/src/index.tsx b/src/index.tsx index aa5bd5b..a3d1e25 100644 --- a/src/index.tsx +++ b/src/index.tsx @@ -2021,12 +2021,14 @@ export type ShotGql = { createdAt?: Maybe; cueObjectFeatures?: Maybe; endFrame: Scalars["Int"]["output"]; + endTime: Scalars["Float"]["output"]; falsePositiveScore?: Maybe; id: Scalars["Int"]["output"]; pocketingIntentionFeatures?: Maybe; pocketingIntentionInfo?: Maybe; serializedShotPaths?: Maybe; startFrame: Scalars["Int"]["output"]; + startTime: Scalars["Float"]["output"]; updatedAt?: Maybe; user?: Maybe; video?: Maybe; @@ -2473,6 +2475,8 @@ export type GetShotsWithMetadataFilterResultQuery = { videoId: number; startFrame: number; endFrame: number; + startTime: number; + endTime: number; falsePositiveScore?: number | null; createdAt?: any | null; updatedAt?: any | null; @@ -2539,6 +2543,8 @@ export type GetShotsWithMetadataQuery = { videoId: number; startFrame: number; endFrame: number; + startTime: number; + endTime: number; falsePositiveScore?: number | null; createdAt?: any | null; updatedAt?: any | null; @@ -2598,6 +2604,8 @@ export type GetShotsByIdsQuery = { videoId: number; startFrame: number; endFrame: number; + startTime: number; + endTime: number; falsePositiveScore?: number | null; createdAt?: any | null; updatedAt?: any | null; @@ -2650,6 +2658,8 @@ export type ShotWithAllFeaturesFragment = { videoId: number; startFrame: number; endFrame: number; + startTime: number; + endTime: number; falsePositiveScore?: number | null; createdAt?: any | null; updatedAt?: any | null; @@ -3311,6 +3321,8 @@ export const ShotWithAllFeaturesFragmentDoc = gql` videoId startFrame endFrame + startTime @client + endTime @client user { id } diff --git a/src/operations/shots.gql b/src/operations/shots.gql index 9a90273..327a941 100644 --- a/src/operations/shots.gql +++ b/src/operations/shots.gql @@ -84,6 +84,8 @@ fragment ShotWithAllFeatures on ShotGQL { videoId startFrame endFrame + startTime @client + endTime @client user { id }