Compare commits
10 Commits
dc9cb6cdaf
...
mk/video-c
| Author | SHA1 | Date | |
|---|---|---|---|
| 6a17c8e3cd | |||
| 653f31e96a | |||
| b18fedae8e | |||
| 31baa2b096 | |||
| 85cd37f70f | |||
| b53aa172fa | |||
| df2e534745 | |||
|
|
ea4980947f | ||
| 65475bca9b | |||
| 280f5a66bd |
112
src/index.tsx
112
src/index.tsx
@@ -122,6 +122,16 @@ export enum ClientUploadStatusEnum {
|
|||||||
UploadEnabled = "UPLOAD_ENABLED",
|
UploadEnabled = "UPLOAD_ENABLED",
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export type CommentGql = {
|
||||||
|
__typename?: "CommentGQL";
|
||||||
|
createdAt?: Maybe<Scalars["DateTime"]["output"]>;
|
||||||
|
id: Scalars["Int"]["output"];
|
||||||
|
message: Scalars["String"]["output"];
|
||||||
|
replies: Array<CommentGql>;
|
||||||
|
updatedAt?: Maybe<Scalars["DateTime"]["output"]>;
|
||||||
|
user: UserGql;
|
||||||
|
};
|
||||||
|
|
||||||
export type CountLeaderboardGql = {
|
export type CountLeaderboardGql = {
|
||||||
__typename?: "CountLeaderboardGQL";
|
__typename?: "CountLeaderboardGQL";
|
||||||
entries: Array<UserShotCountEntry>;
|
entries: Array<UserShotCountEntry>;
|
||||||
@@ -2226,10 +2236,13 @@ export type MustHaveSetForUploadLinkErrSegmentAlreadyUploadedErrProcessingFailed
|
|||||||
export type Mutation = {
|
export type Mutation = {
|
||||||
__typename?: "Mutation";
|
__typename?: "Mutation";
|
||||||
addAnnotationToShot: AddShotAnnotationReturn;
|
addAnnotationToShot: AddShotAnnotationReturn;
|
||||||
|
commentOnVideo: Scalars["Boolean"]["output"];
|
||||||
createBucketSet: BucketSetGql;
|
createBucketSet: BucketSetGql;
|
||||||
createUploadStream: CreateUploadStreamReturn;
|
createUploadStream: CreateUploadStreamReturn;
|
||||||
|
deleteComment: Scalars["Boolean"]["output"];
|
||||||
deleteTags: Scalars["Boolean"]["output"];
|
deleteTags: Scalars["Boolean"]["output"];
|
||||||
deleteVideo: Scalars["Boolean"]["output"];
|
deleteVideo: Scalars["Boolean"]["output"];
|
||||||
|
editComment: Scalars["Boolean"]["output"];
|
||||||
editProfileImageUri: UserGql;
|
editProfileImageUri: UserGql;
|
||||||
editShot: EditShotReturn;
|
editShot: EditShotReturn;
|
||||||
editUploadStream: Scalars["Boolean"]["output"];
|
editUploadStream: Scalars["Boolean"]["output"];
|
||||||
@@ -2253,6 +2266,12 @@ export type MutationAddAnnotationToShotArgs = {
|
|||||||
shotId: Scalars["Int"]["input"];
|
shotId: Scalars["Int"]["input"];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
export type MutationCommentOnVideoArgs = {
|
||||||
|
message: Scalars["String"]["input"];
|
||||||
|
parentCommentId?: InputMaybe<Scalars["Int"]["input"]>;
|
||||||
|
videoId: Scalars["Int"]["input"];
|
||||||
|
};
|
||||||
|
|
||||||
export type MutationCreateBucketSetArgs = {
|
export type MutationCreateBucketSetArgs = {
|
||||||
params: CreateBucketSetInput;
|
params: CreateBucketSetInput;
|
||||||
};
|
};
|
||||||
@@ -2261,6 +2280,11 @@ export type MutationCreateUploadStreamArgs = {
|
|||||||
videoMetadata: VideoMetadataInput;
|
videoMetadata: VideoMetadataInput;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
export type MutationDeleteCommentArgs = {
|
||||||
|
commentId: Scalars["Int"]["input"];
|
||||||
|
videoId: Scalars["Int"]["input"];
|
||||||
|
};
|
||||||
|
|
||||||
export type MutationDeleteTagsArgs = {
|
export type MutationDeleteTagsArgs = {
|
||||||
tagsToDelete: Array<VideoTagInput>;
|
tagsToDelete: Array<VideoTagInput>;
|
||||||
videoId: Scalars["Int"]["input"];
|
videoId: Scalars["Int"]["input"];
|
||||||
@@ -2270,6 +2294,12 @@ export type MutationDeleteVideoArgs = {
|
|||||||
videoId: Scalars["Int"]["input"];
|
videoId: Scalars["Int"]["input"];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
export type MutationEditCommentArgs = {
|
||||||
|
commentId: Scalars["Int"]["input"];
|
||||||
|
newMessage: Scalars["String"]["input"];
|
||||||
|
videoId: Scalars["Int"]["input"];
|
||||||
|
};
|
||||||
|
|
||||||
export type MutationEditProfileImageUriArgs = {
|
export type MutationEditProfileImageUriArgs = {
|
||||||
profileImageUri: Scalars["String"]["input"];
|
profileImageUri: Scalars["String"]["input"];
|
||||||
};
|
};
|
||||||
@@ -3008,6 +3038,7 @@ export type VideoGql = {
|
|||||||
__typename?: "VideoGQL";
|
__typename?: "VideoGQL";
|
||||||
averageDifficulty?: Maybe<Scalars["Float"]["output"]>;
|
averageDifficulty?: Maybe<Scalars["Float"]["output"]>;
|
||||||
averageTimeBetweenShots?: Maybe<Scalars["Float"]["output"]>;
|
averageTimeBetweenShots?: Maybe<Scalars["Float"]["output"]>;
|
||||||
|
comments: Array<CommentGql>;
|
||||||
createdAt?: Maybe<Scalars["DateTime"]["output"]>;
|
createdAt?: Maybe<Scalars["DateTime"]["output"]>;
|
||||||
currentHomography?: Maybe<HomographyInfoGql>;
|
currentHomography?: Maybe<HomographyInfoGql>;
|
||||||
currentProcessing?: Maybe<VideoProcessingGql>;
|
currentProcessing?: Maybe<VideoProcessingGql>;
|
||||||
@@ -3214,7 +3245,12 @@ export type GetFeedQuery = {
|
|||||||
__typename?: "ReactionGQL";
|
__typename?: "ReactionGQL";
|
||||||
videoId: number;
|
videoId: number;
|
||||||
reaction: ReactionEnum;
|
reaction: ReactionEnum;
|
||||||
user: { __typename?: "UserGQL"; id: number; username: string };
|
user: {
|
||||||
|
__typename?: "UserGQL";
|
||||||
|
id: number;
|
||||||
|
username: string;
|
||||||
|
profileImageUri?: string | null;
|
||||||
|
};
|
||||||
}>;
|
}>;
|
||||||
}>;
|
}>;
|
||||||
pageInfo: {
|
pageInfo: {
|
||||||
@@ -3273,7 +3309,12 @@ export type VideoCardFieldsFragment = {
|
|||||||
__typename?: "ReactionGQL";
|
__typename?: "ReactionGQL";
|
||||||
videoId: number;
|
videoId: number;
|
||||||
reaction: ReactionEnum;
|
reaction: ReactionEnum;
|
||||||
user: { __typename?: "UserGQL"; id: number; username: string };
|
user: {
|
||||||
|
__typename?: "UserGQL";
|
||||||
|
id: number;
|
||||||
|
username: string;
|
||||||
|
profileImageUri?: string | null;
|
||||||
|
};
|
||||||
}>;
|
}>;
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -3341,7 +3382,12 @@ export type GetVideoFeedQuery = {
|
|||||||
__typename?: "ReactionGQL";
|
__typename?: "ReactionGQL";
|
||||||
videoId: number;
|
videoId: number;
|
||||||
reaction: ReactionEnum;
|
reaction: ReactionEnum;
|
||||||
user: { __typename?: "UserGQL"; id: number; username: string };
|
user: {
|
||||||
|
__typename?: "UserGQL";
|
||||||
|
id: number;
|
||||||
|
username: string;
|
||||||
|
profileImageUri?: string | null;
|
||||||
|
};
|
||||||
}>;
|
}>;
|
||||||
}>;
|
}>;
|
||||||
pageInfo: {
|
pageInfo: {
|
||||||
@@ -4006,6 +4052,16 @@ export type RetireTagsMutation = {
|
|||||||
retireTags: boolean;
|
retireTags: boolean;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
export type DeleteTagsMutationVariables = Exact<{
|
||||||
|
videoId: Scalars["Int"]["input"];
|
||||||
|
tagsToDelete: Array<VideoTagInput> | VideoTagInput;
|
||||||
|
}>;
|
||||||
|
|
||||||
|
export type DeleteTagsMutation = {
|
||||||
|
__typename?: "Mutation";
|
||||||
|
deleteTags: boolean;
|
||||||
|
};
|
||||||
|
|
||||||
export type GetProfileImageUploadLinkMutationVariables = Exact<{
|
export type GetProfileImageUploadLinkMutationVariables = Exact<{
|
||||||
fileExt?: InputMaybe<Scalars["String"]["input"]>;
|
fileExt?: InputMaybe<Scalars["String"]["input"]>;
|
||||||
}>;
|
}>;
|
||||||
@@ -5029,6 +5085,7 @@ export const VideoCardFieldsFragmentDoc = gql`
|
|||||||
user {
|
user {
|
||||||
id
|
id
|
||||||
username
|
username
|
||||||
|
profileImageUri
|
||||||
}
|
}
|
||||||
reaction
|
reaction
|
||||||
}
|
}
|
||||||
@@ -6861,6 +6918,55 @@ export type RetireTagsMutationOptions = Apollo.BaseMutationOptions<
|
|||||||
RetireTagsMutation,
|
RetireTagsMutation,
|
||||||
RetireTagsMutationVariables
|
RetireTagsMutationVariables
|
||||||
>;
|
>;
|
||||||
|
export const DeleteTagsDocument = gql`
|
||||||
|
mutation DeleteTags($videoId: Int!, $tagsToDelete: [VideoTagInput!]!) {
|
||||||
|
deleteTags(videoId: $videoId, tagsToDelete: $tagsToDelete)
|
||||||
|
}
|
||||||
|
`;
|
||||||
|
export type DeleteTagsMutationFn = Apollo.MutationFunction<
|
||||||
|
DeleteTagsMutation,
|
||||||
|
DeleteTagsMutationVariables
|
||||||
|
>;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* __useDeleteTagsMutation__
|
||||||
|
*
|
||||||
|
* To run a mutation, you first call `useDeleteTagsMutation` within a React component and pass it any options that fit your needs.
|
||||||
|
* When your component renders, `useDeleteTagsMutation` returns a tuple that includes:
|
||||||
|
* - A mutate function that you can call at any time to execute the mutation
|
||||||
|
* - An object with fields that represent the current status of the mutation's execution
|
||||||
|
*
|
||||||
|
* @param baseOptions options that will be passed into the mutation, supported options are listed on: https://www.apollographql.com/docs/react/api/react-hooks/#options-2;
|
||||||
|
*
|
||||||
|
* @example
|
||||||
|
* const [deleteTagsMutation, { data, loading, error }] = useDeleteTagsMutation({
|
||||||
|
* variables: {
|
||||||
|
* videoId: // value for 'videoId'
|
||||||
|
* tagsToDelete: // value for 'tagsToDelete'
|
||||||
|
* },
|
||||||
|
* });
|
||||||
|
*/
|
||||||
|
export function useDeleteTagsMutation(
|
||||||
|
baseOptions?: Apollo.MutationHookOptions<
|
||||||
|
DeleteTagsMutation,
|
||||||
|
DeleteTagsMutationVariables
|
||||||
|
>,
|
||||||
|
) {
|
||||||
|
const options = { ...defaultOptions, ...baseOptions };
|
||||||
|
return Apollo.useMutation<DeleteTagsMutation, DeleteTagsMutationVariables>(
|
||||||
|
DeleteTagsDocument,
|
||||||
|
options,
|
||||||
|
);
|
||||||
|
}
|
||||||
|
export type DeleteTagsMutationHookResult = ReturnType<
|
||||||
|
typeof useDeleteTagsMutation
|
||||||
|
>;
|
||||||
|
export type DeleteTagsMutationResult =
|
||||||
|
Apollo.MutationResult<DeleteTagsMutation>;
|
||||||
|
export type DeleteTagsMutationOptions = Apollo.BaseMutationOptions<
|
||||||
|
DeleteTagsMutation,
|
||||||
|
DeleteTagsMutationVariables
|
||||||
|
>;
|
||||||
export const GetProfileImageUploadLinkDocument = gql`
|
export const GetProfileImageUploadLinkDocument = gql`
|
||||||
mutation getProfileImageUploadLink($fileExt: String = ".png") {
|
mutation getProfileImageUploadLink($fileExt: String = ".png") {
|
||||||
getProfileImageUploadLink(fileExt: $fileExt) {
|
getProfileImageUploadLink(fileExt: $fileExt) {
|
||||||
|
|||||||
@@ -63,6 +63,7 @@ fragment VideoCardFields on VideoGQL {
|
|||||||
user {
|
user {
|
||||||
id
|
id
|
||||||
username
|
username
|
||||||
|
profileImageUri
|
||||||
}
|
}
|
||||||
reaction
|
reaction
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,3 +1,7 @@
|
|||||||
mutation RetireTags($tagIds: [Int!]!) {
|
mutation RetireTags($tagIds: [Int!]!) {
|
||||||
retireTags(tagIds: $tagIds)
|
retireTags(tagIds: $tagIds)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
mutation DeleteTags($videoId: Int!, $tagsToDelete: [VideoTagInput!]!) {
|
||||||
|
deleteTags(videoId: $videoId, tagsToDelete: $tagsToDelete)
|
||||||
|
}
|
||||||
|
|||||||
@@ -480,6 +480,7 @@ type VideoGQL {
|
|||||||
homographyHistory: [HomographyInfoGQL!]!
|
homographyHistory: [HomographyInfoGQL!]!
|
||||||
currentProcessing: VideoProcessingGQL
|
currentProcessing: VideoProcessingGQL
|
||||||
reactions: [ReactionGQL!]!
|
reactions: [ReactionGQL!]!
|
||||||
|
comments: [CommentGQL!]!
|
||||||
}
|
}
|
||||||
|
|
||||||
type UploadStreamGQL {
|
type UploadStreamGQL {
|
||||||
@@ -621,6 +622,15 @@ type ReactionGQL {
|
|||||||
updatedAt: DateTime
|
updatedAt: DateTime
|
||||||
}
|
}
|
||||||
|
|
||||||
|
type CommentGQL {
|
||||||
|
id: Int!
|
||||||
|
user: UserGQL!
|
||||||
|
message: String!
|
||||||
|
replies: [CommentGQL!]!
|
||||||
|
createdAt: DateTime
|
||||||
|
updatedAt: DateTime
|
||||||
|
}
|
||||||
|
|
||||||
enum ReactionEnum {
|
enum ReactionEnum {
|
||||||
LIKE
|
LIKE
|
||||||
HEART
|
HEART
|
||||||
@@ -818,6 +828,13 @@ type Mutation {
|
|||||||
deleteVideo(videoId: Int!): Boolean!
|
deleteVideo(videoId: Int!): Boolean!
|
||||||
deleteTags(videoId: Int!, tagsToDelete: [VideoTagInput!]!): Boolean!
|
deleteTags(videoId: Int!, tagsToDelete: [VideoTagInput!]!): Boolean!
|
||||||
reactToVideo(videoId: Int!, reaction: ReactionEnum): Boolean!
|
reactToVideo(videoId: Int!, reaction: ReactionEnum): Boolean!
|
||||||
|
commentOnVideo(
|
||||||
|
videoId: Int!
|
||||||
|
message: String!
|
||||||
|
parentCommentId: Int
|
||||||
|
): Boolean!
|
||||||
|
editComment(videoId: Int!, commentId: Int!, newMessage: String!): Boolean!
|
||||||
|
deleteComment(videoId: Int!, commentId: Int!): Boolean!
|
||||||
}
|
}
|
||||||
|
|
||||||
input CreateBucketSetInput {
|
input CreateBucketSetInput {
|
||||||
|
|||||||
Reference in New Issue
Block a user