graphql-codegen-plugin-typescript-swr 0.8.4 → 0.8.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (124) hide show
  1. package/README.md +5 -0
  2. package/build/main/config.d.ts +27 -0
  3. package/build/main/config.js +3 -0
  4. package/build/main/index.d.ts +6 -0
  5. package/build/main/index.js +35 -0
  6. package/build/main/visitor.d.ts +30 -0
  7. package/build/main/visitor.js +160 -0
  8. package/build/module/config.d.ts +27 -0
  9. package/build/module/config.js +2 -0
  10. package/build/module/index.d.ts +6 -0
  11. package/build/module/index.js +30 -0
  12. package/build/module/visitor.d.ts +30 -0
  13. package/build/module/visitor.js +153 -0
  14. package/package.json +5 -2
  15. package/.editorconfig +0 -13
  16. package/.eslintrc.js +0 -63
  17. package/.github/CONTRIBUTING.md +0 -3
  18. package/.github/ISSUE_TEMPLATE.md +0 -9
  19. package/.github/PULL_REQUEST_TEMPLATE.md +0 -7
  20. package/.github/workflows/main.yml +0 -28
  21. package/.gitignore +0 -8
  22. package/.prettierignore +0 -3
  23. package/.prettierrc.json +0 -4
  24. package/.vscode/extensions.json +0 -8
  25. package/.vscode/launch.json +0 -29
  26. package/.vscode/settings.json +0 -41
  27. package/dev-test/.env +0 -1
  28. package/dev-test/codegen.yml +0 -357
  29. package/dev-test/githunt/__generated__/comment-added.subscription.stencil-component.tsx +0 -47
  30. package/dev-test/githunt/__generated__/comment.query.stencil-component.tsx +0 -68
  31. package/dev-test/githunt/__generated__/comments-page-comment.fragment.stencil-component.tsx +0 -20
  32. package/dev-test/githunt/__generated__/current-user.query.stencil-component.tsx +0 -34
  33. package/dev-test/githunt/__generated__/feed-entry.fragment.stencil-component.tsx +0 -30
  34. package/dev-test/githunt/__generated__/feed.query.stencil-component.tsx +0 -40
  35. package/dev-test/githunt/__generated__/new-entry.mutation.stencil-component.tsx +0 -35
  36. package/dev-test/githunt/__generated__/repo-info.fragment.stencil-component.tsx +0 -26
  37. package/dev-test/githunt/__generated__/submit-comment.mutation.stencil-component.tsx +0 -35
  38. package/dev-test/githunt/__generated__/vote-buttons.fragment.stencil-component.tsx +0 -16
  39. package/dev-test/githunt/__generated__/vote.mutation.stencil-component.tsx +0 -41
  40. package/dev-test/githunt/comment-added.subscription.graphql +0 -11
  41. package/dev-test/githunt/comment.query.graphql +0 -33
  42. package/dev-test/githunt/comments-page-comment.fragment.graphql +0 -9
  43. package/dev-test/githunt/current-user.query.graphql +0 -6
  44. package/dev-test/githunt/feed-entry.fragment.graphql +0 -13
  45. package/dev-test/githunt/feed.query.graphql +0 -8
  46. package/dev-test/githunt/flow.flow.js +0 -367
  47. package/dev-test/githunt/graphql-declared-modules.d.ts +0 -87
  48. package/dev-test/githunt/new-entry.mutation.graphql +0 -5
  49. package/dev-test/githunt/repo-info.fragment.graphql +0 -12
  50. package/dev-test/githunt/schema.js +0 -3
  51. package/dev-test/githunt/schema.json +0 -1750
  52. package/dev-test/githunt/submit-comment.mutation.graphql +0 -5
  53. package/dev-test/githunt/typed-document-nodes.ts +0 -892
  54. package/dev-test/githunt/types.apolloAngular.sdk.ts +0 -570
  55. package/dev-test/githunt/types.apolloAngular.ts +0 -491
  56. package/dev-test/githunt/types.avoidOptionals.ts +0 -266
  57. package/dev-test/githunt/types.d.ts +0 -261
  58. package/dev-test/githunt/types.enumsAsTypes.ts +0 -261
  59. package/dev-test/githunt/types.flatten.preResolveTypes.ts +0 -289
  60. package/dev-test/githunt/types.immutableTypes.ts +0 -267
  61. package/dev-test/githunt/types.preResolveTypes.compatibility.ts +0 -368
  62. package/dev-test/githunt/types.preResolveTypes.onlyOperationTypes.ts +0 -156
  63. package/dev-test/githunt/types.preResolveTypes.ts +0 -293
  64. package/dev-test/githunt/types.reactApollo.customSuffix.tsx +0 -634
  65. package/dev-test/githunt/types.reactApollo.hooks.tsx +0 -621
  66. package/dev-test/githunt/types.reactApollo.preResolveTypes.tsx +0 -648
  67. package/dev-test/githunt/types.reactApollo.tsx +0 -621
  68. package/dev-test/githunt/types.reactApollo.v2.tsx +0 -635
  69. package/dev-test/githunt/types.stencilApollo.tsx +0 -484
  70. package/dev-test/githunt/types.ts +0 -266
  71. package/dev-test/githunt/types.urql.tsx +0 -444
  72. package/dev-test/githunt/types.vueApollo.ts +0 -647
  73. package/dev-test/githunt/vote-buttons.fragment.graphql +0 -6
  74. package/dev-test/githunt/vote.mutation.graphql +0 -9
  75. package/dev-test/setup.js +0 -3
  76. package/dev-test/test-message/documents.ts +0 -46
  77. package/dev-test/test-message/schema.graphql +0 -23
  78. package/dev-test/test-message/types.tsx +0 -237
  79. package/dev-test/test-schema/env.types.ts +0 -35
  80. package/dev-test/test-schema/flow-types.flow.js +0 -139
  81. package/dev-test/test-schema/local/schema-ast.js +0 -2
  82. package/dev-test/test-schema/local/schema-formats.js +0 -20
  83. package/dev-test/test-schema/local/schema-object.js +0 -2
  84. package/dev-test/test-schema/local/schema-text.js +0 -2
  85. package/dev-test/test-schema/local/schema.graphql +0 -8
  86. package/dev-test/test-schema/resolvers-federation.ts +0 -233
  87. package/dev-test/test-schema/resolvers-root.ts +0 -178
  88. package/dev-test/test-schema/resolvers-types.ts +0 -168
  89. package/dev-test/test-schema/schema-ast.js +0 -2
  90. package/dev-test/test-schema/schema-federation.graphql +0 -30
  91. package/dev-test/test-schema/schema-formats.js +0 -38
  92. package/dev-test/test-schema/schema-json.js +0 -2
  93. package/dev-test/test-schema/schema-object.js +0 -2
  94. package/dev-test/test-schema/schema-text.js +0 -2
  95. package/dev-test/test-schema/schema-with-imports.graphql +0 -9
  96. package/dev-test/test-schema/schema-with-root.graphql +0 -22
  97. package/dev-test/test-schema/schema.graphql +0 -19
  98. package/dev-test/test-schema/schema.json +0 -1070
  99. package/dev-test/test-schema/types.preResolveTypes.onlyOperationTypes.ts +0 -19
  100. package/dev-test/test-schema/types.preResolveTypes.ts +0 -44
  101. package/dev-test/test-schema/typings.avoidOptionals.ts +0 -27
  102. package/dev-test/test-schema/typings.enum.ts +0 -19
  103. package/dev-test/test-schema/typings.immutableTypes.ts +0 -27
  104. package/dev-test/test-schema/typings.ts +0 -156
  105. package/dev-test/test-schema/typings.wrapped.ts +0 -29
  106. package/dev-test/tsconfig.json +0 -18
  107. package/jest.config.js +0 -30
  108. package/renovate.json +0 -2
  109. package/src/config.ts +0 -29
  110. package/src/index.ts +0 -54
  111. package/src/visitor.ts +0 -259
  112. package/tests/outputs/autogenSWRKey.ts +0 -46
  113. package/tests/outputs/excludeQueries.ts +0 -13
  114. package/tests/outputs/infinite.ts +0 -49
  115. package/tests/outputs/mutations.ts +0 -19
  116. package/tests/outputs/rawRequest.ts +0 -19
  117. package/tests/outputs/straight.ts +0 -19
  118. package/tests/swr.spec.ts +0 -306
  119. package/tests/visitor.spec.ts +0 -19
  120. package/tsconfig.json +0 -32
  121. package/tsconfig.main.json +0 -11
  122. package/tsconfig.module.json +0 -13
  123. package/yarn-error.log +0 -5477
  124. package/yarn.lock +0 -5359
@@ -1,491 +0,0 @@
1
- import { gql } from 'apollo-angular';
2
- import { Injectable } from '@angular/core';
3
- import * as Apollo from 'apollo-angular';
4
- export type Maybe<T> = T | null;
5
- export type Exact<T extends { [key: string]: unknown }> = { [K in keyof T]: T[K] };
6
- /** All built-in and custom scalars, mapped to their actual values */
7
- export type Scalars = {
8
- ID: string;
9
- String: string;
10
- Boolean: boolean;
11
- Int: number;
12
- Float: number;
13
- };
14
-
15
- export type Query = {
16
- __typename?: 'Query';
17
- /** A feed of repository submissions */
18
- feed?: Maybe<Array<Maybe<Entry>>>;
19
- /** A single entry */
20
- entry?: Maybe<Entry>;
21
- /** Return the currently logged in user, or null if nobody is logged in */
22
- currentUser?: Maybe<User>;
23
- };
24
-
25
- export type QueryFeedArgs = {
26
- type: FeedType;
27
- offset?: Maybe<Scalars['Int']>;
28
- limit?: Maybe<Scalars['Int']>;
29
- };
30
-
31
- export type QueryEntryArgs = {
32
- repoFullName: Scalars['String'];
33
- };
34
-
35
- /** A list of options for the sort order of the feed */
36
- export enum FeedType {
37
- /** Sort by a combination of freshness and score, using Reddit's algorithm */
38
- Hot = 'HOT',
39
- /** Newest entries first */
40
- New = 'NEW',
41
- /** Highest score entries first */
42
- Top = 'TOP',
43
- }
44
-
45
- /** Information about a GitHub repository submitted to GitHunt */
46
- export type Entry = {
47
- __typename?: 'Entry';
48
- /** Information about the repository from GitHub */
49
- repository: Repository;
50
- /** The GitHub user who submitted this entry */
51
- postedBy: User;
52
- /** A timestamp of when the entry was submitted */
53
- createdAt: Scalars['Float'];
54
- /** The score of this repository, upvotes - downvotes */
55
- score: Scalars['Int'];
56
- /** The hot score of this repository */
57
- hotScore: Scalars['Float'];
58
- /** Comments posted about this repository */
59
- comments: Array<Maybe<Comment>>;
60
- /** The number of comments posted about this repository */
61
- commentCount: Scalars['Int'];
62
- /** The SQL ID of this entry */
63
- id: Scalars['Int'];
64
- /** XXX to be changed */
65
- vote: Vote;
66
- };
67
-
68
- /** Information about a GitHub repository submitted to GitHunt */
69
- export type EntryCommentsArgs = {
70
- limit?: Maybe<Scalars['Int']>;
71
- offset?: Maybe<Scalars['Int']>;
72
- };
73
-
74
- /**
75
- * A repository object from the GitHub API. This uses the exact field names returned by the
76
- * GitHub API for simplicity, even though the convention for GraphQL is usually to camel case.
77
- */
78
- export type Repository = {
79
- __typename?: 'Repository';
80
- /** Just the name of the repository, e.g. GitHunt-API */
81
- name: Scalars['String'];
82
- /** The full name of the repository with the username, e.g. apollostack/GitHunt-API */
83
- full_name: Scalars['String'];
84
- /** The description of the repository */
85
- description?: Maybe<Scalars['String']>;
86
- /** The link to the repository on GitHub */
87
- html_url: Scalars['String'];
88
- /** The number of people who have starred this repository on GitHub */
89
- stargazers_count: Scalars['Int'];
90
- /** The number of open issues on this repository on GitHub */
91
- open_issues_count?: Maybe<Scalars['Int']>;
92
- /** The owner of this repository on GitHub, e.g. apollostack */
93
- owner?: Maybe<User>;
94
- };
95
-
96
- /** A user object from the GitHub API. This uses the exact field names returned from the GitHub API. */
97
- export type User = {
98
- __typename?: 'User';
99
- /** The name of the user, e.g. apollostack */
100
- login: Scalars['String'];
101
- /** The URL to a directly embeddable image for this user's avatar */
102
- avatar_url: Scalars['String'];
103
- /** The URL of this user's GitHub page */
104
- html_url: Scalars['String'];
105
- };
106
-
107
- /** A comment about an entry, submitted by a user */
108
- export type Comment = {
109
- __typename?: 'Comment';
110
- /** The SQL ID of this entry */
111
- id: Scalars['Int'];
112
- /** The GitHub user who posted the comment */
113
- postedBy: User;
114
- /** A timestamp of when the comment was posted */
115
- createdAt: Scalars['Float'];
116
- /** The text of the comment */
117
- content: Scalars['String'];
118
- /** The repository which this comment is about */
119
- repoName: Scalars['String'];
120
- };
121
-
122
- /** XXX to be removed */
123
- export type Vote = {
124
- __typename?: 'Vote';
125
- vote_value: Scalars['Int'];
126
- };
127
-
128
- export type Mutation = {
129
- __typename?: 'Mutation';
130
- /** Submit a new repository, returns the new submission */
131
- submitRepository?: Maybe<Entry>;
132
- /** Vote on a repository submission, returns the submission that was voted on */
133
- vote?: Maybe<Entry>;
134
- /** Comment on a repository, returns the new comment */
135
- submitComment?: Maybe<Comment>;
136
- };
137
-
138
- export type MutationSubmitRepositoryArgs = {
139
- repoFullName: Scalars['String'];
140
- };
141
-
142
- export type MutationVoteArgs = {
143
- repoFullName: Scalars['String'];
144
- type: VoteType;
145
- };
146
-
147
- export type MutationSubmitCommentArgs = {
148
- repoFullName: Scalars['String'];
149
- commentContent: Scalars['String'];
150
- };
151
-
152
- /** The type of vote to record, when submitting a vote */
153
- export enum VoteType {
154
- Up = 'UP',
155
- Down = 'DOWN',
156
- Cancel = 'CANCEL',
157
- }
158
-
159
- export type Subscription = {
160
- __typename?: 'Subscription';
161
- /** Subscription fires on every comment added */
162
- commentAdded?: Maybe<Comment>;
163
- };
164
-
165
- export type SubscriptionCommentAddedArgs = {
166
- repoFullName: Scalars['String'];
167
- };
168
-
169
- export type OnCommentAddedSubscriptionVariables = Exact<{
170
- repoFullName: Scalars['String'];
171
- }>;
172
-
173
- export type OnCommentAddedSubscription = { __typename?: 'Subscription' } & {
174
- commentAdded?: Maybe<
175
- { __typename?: 'Comment' } & Pick<Comment, 'id' | 'createdAt' | 'content'> & {
176
- postedBy: { __typename?: 'User' } & Pick<User, 'login' | 'html_url'>;
177
- }
178
- >;
179
- };
180
-
181
- export type CommentQueryVariables = Exact<{
182
- repoFullName: Scalars['String'];
183
- limit?: Maybe<Scalars['Int']>;
184
- offset?: Maybe<Scalars['Int']>;
185
- }>;
186
-
187
- export type CommentQuery = { __typename?: 'Query' } & {
188
- currentUser?: Maybe<{ __typename?: 'User' } & Pick<User, 'login' | 'html_url'>>;
189
- entry?: Maybe<
190
- { __typename?: 'Entry' } & Pick<Entry, 'id' | 'createdAt' | 'commentCount'> & {
191
- postedBy: { __typename?: 'User' } & Pick<User, 'login' | 'html_url'>;
192
- comments: Array<Maybe<{ __typename?: 'Comment' } & CommentsPageCommentFragment>>;
193
- repository: { __typename?: 'Repository' } & Pick<
194
- Repository,
195
- 'description' | 'open_issues_count' | 'stargazers_count' | 'full_name' | 'html_url'
196
- >;
197
- }
198
- >;
199
- };
200
-
201
- export type CommentsPageCommentFragment = { __typename?: 'Comment' } & Pick<Comment, 'id' | 'createdAt' | 'content'> & {
202
- postedBy: { __typename?: 'User' } & Pick<User, 'login' | 'html_url'>;
203
- };
204
-
205
- export type CurrentUserForProfileQueryVariables = Exact<{ [key: string]: never }>;
206
-
207
- export type CurrentUserForProfileQuery = { __typename?: 'Query' } & {
208
- currentUser?: Maybe<{ __typename?: 'User' } & Pick<User, 'login' | 'avatar_url'>>;
209
- };
210
-
211
- export type FeedEntryFragment = { __typename?: 'Entry' } & Pick<Entry, 'id' | 'commentCount'> & {
212
- repository: { __typename?: 'Repository' } & Pick<Repository, 'full_name' | 'html_url'> & {
213
- owner?: Maybe<{ __typename?: 'User' } & Pick<User, 'avatar_url'>>;
214
- };
215
- } & VoteButtonsFragment &
216
- RepoInfoFragment;
217
-
218
- export type FeedQueryVariables = Exact<{
219
- type: FeedType;
220
- offset?: Maybe<Scalars['Int']>;
221
- limit?: Maybe<Scalars['Int']>;
222
- }>;
223
-
224
- export type FeedQuery = { __typename?: 'Query' } & {
225
- currentUser?: Maybe<{ __typename?: 'User' } & Pick<User, 'login'>>;
226
- feed?: Maybe<Array<Maybe<{ __typename?: 'Entry' } & FeedEntryFragment>>>;
227
- };
228
-
229
- export type SubmitRepositoryMutationVariables = Exact<{
230
- repoFullName: Scalars['String'];
231
- }>;
232
-
233
- export type SubmitRepositoryMutation = { __typename?: 'Mutation' } & {
234
- submitRepository?: Maybe<{ __typename?: 'Entry' } & Pick<Entry, 'createdAt'>>;
235
- };
236
-
237
- export type RepoInfoFragment = { __typename?: 'Entry' } & Pick<Entry, 'createdAt'> & {
238
- repository: { __typename?: 'Repository' } & Pick<
239
- Repository,
240
- 'description' | 'stargazers_count' | 'open_issues_count'
241
- >;
242
- postedBy: { __typename?: 'User' } & Pick<User, 'html_url' | 'login'>;
243
- };
244
-
245
- export type SubmitCommentMutationVariables = Exact<{
246
- repoFullName: Scalars['String'];
247
- commentContent: Scalars['String'];
248
- }>;
249
-
250
- export type SubmitCommentMutation = { __typename?: 'Mutation' } & {
251
- submitComment?: Maybe<{ __typename?: 'Comment' } & CommentsPageCommentFragment>;
252
- };
253
-
254
- export type VoteButtonsFragment = { __typename?: 'Entry' } & Pick<Entry, 'score'> & {
255
- vote: { __typename?: 'Vote' } & Pick<Vote, 'vote_value'>;
256
- };
257
-
258
- export type VoteMutationVariables = Exact<{
259
- repoFullName: Scalars['String'];
260
- type: VoteType;
261
- }>;
262
-
263
- export type VoteMutation = { __typename?: 'Mutation' } & {
264
- vote?: Maybe<
265
- { __typename?: 'Entry' } & Pick<Entry, 'score' | 'id'> & {
266
- vote: { __typename?: 'Vote' } & Pick<Vote, 'vote_value'>;
267
- }
268
- >;
269
- };
270
-
271
- export const CommentsPageCommentFragmentDoc = gql`
272
- fragment CommentsPageComment on Comment {
273
- id
274
- postedBy {
275
- login
276
- html_url
277
- }
278
- createdAt
279
- content
280
- }
281
- `;
282
- export const VoteButtonsFragmentDoc = gql`
283
- fragment VoteButtons on Entry {
284
- score
285
- vote {
286
- vote_value
287
- }
288
- }
289
- `;
290
- export const RepoInfoFragmentDoc = gql`
291
- fragment RepoInfo on Entry {
292
- createdAt
293
- repository {
294
- description
295
- stargazers_count
296
- open_issues_count
297
- }
298
- postedBy {
299
- html_url
300
- login
301
- }
302
- }
303
- `;
304
- export const FeedEntryFragmentDoc = gql`
305
- fragment FeedEntry on Entry {
306
- id
307
- commentCount
308
- repository {
309
- full_name
310
- html_url
311
- owner {
312
- avatar_url
313
- }
314
- }
315
- ...VoteButtons
316
- ...RepoInfo
317
- }
318
- ${VoteButtonsFragmentDoc}
319
- ${RepoInfoFragmentDoc}
320
- `;
321
- export const OnCommentAddedDocument = gql`
322
- subscription onCommentAdded($repoFullName: String!) {
323
- commentAdded(repoFullName: $repoFullName) {
324
- id
325
- postedBy {
326
- login
327
- html_url
328
- }
329
- createdAt
330
- content
331
- }
332
- }
333
- `;
334
-
335
- @Injectable({
336
- providedIn: 'root',
337
- })
338
- export class OnCommentAddedGQL extends Apollo.Subscription<
339
- OnCommentAddedSubscription,
340
- OnCommentAddedSubscriptionVariables
341
- > {
342
- document = OnCommentAddedDocument;
343
-
344
- constructor(apollo: Apollo.Apollo) {
345
- super(apollo);
346
- }
347
- }
348
- export const CommentDocument = gql`
349
- query Comment($repoFullName: String!, $limit: Int, $offset: Int) {
350
- currentUser {
351
- login
352
- html_url
353
- }
354
- entry(repoFullName: $repoFullName) {
355
- id
356
- postedBy {
357
- login
358
- html_url
359
- }
360
- createdAt
361
- comments(limit: $limit, offset: $offset) {
362
- ...CommentsPageComment
363
- }
364
- commentCount
365
- repository {
366
- full_name
367
- html_url
368
- ... on Repository {
369
- description
370
- open_issues_count
371
- stargazers_count
372
- }
373
- }
374
- }
375
- }
376
- ${CommentsPageCommentFragmentDoc}
377
- `;
378
-
379
- @Injectable({
380
- providedIn: 'root',
381
- })
382
- export class CommentGQL extends Apollo.Query<CommentQuery, CommentQueryVariables> {
383
- document = CommentDocument;
384
-
385
- constructor(apollo: Apollo.Apollo) {
386
- super(apollo);
387
- }
388
- }
389
- export const CurrentUserForProfileDocument = gql`
390
- query CurrentUserForProfile {
391
- currentUser {
392
- login
393
- avatar_url
394
- }
395
- }
396
- `;
397
-
398
- @Injectable({
399
- providedIn: 'root',
400
- })
401
- export class CurrentUserForProfileGQL extends Apollo.Query<
402
- CurrentUserForProfileQuery,
403
- CurrentUserForProfileQueryVariables
404
- > {
405
- document = CurrentUserForProfileDocument;
406
-
407
- constructor(apollo: Apollo.Apollo) {
408
- super(apollo);
409
- }
410
- }
411
- export const FeedDocument = gql`
412
- query Feed($type: FeedType!, $offset: Int, $limit: Int) {
413
- currentUser {
414
- login
415
- }
416
- feed(type: $type, offset: $offset, limit: $limit) {
417
- ...FeedEntry
418
- }
419
- }
420
- ${FeedEntryFragmentDoc}
421
- `;
422
-
423
- @Injectable({
424
- providedIn: 'root',
425
- })
426
- export class FeedGQL extends Apollo.Query<FeedQuery, FeedQueryVariables> {
427
- document = FeedDocument;
428
-
429
- constructor(apollo: Apollo.Apollo) {
430
- super(apollo);
431
- }
432
- }
433
- export const SubmitRepositoryDocument = gql`
434
- mutation submitRepository($repoFullName: String!) {
435
- submitRepository(repoFullName: $repoFullName) {
436
- createdAt
437
- }
438
- }
439
- `;
440
-
441
- @Injectable({
442
- providedIn: 'root',
443
- })
444
- export class SubmitRepositoryGQL extends Apollo.Mutation<SubmitRepositoryMutation, SubmitRepositoryMutationVariables> {
445
- document = SubmitRepositoryDocument;
446
-
447
- constructor(apollo: Apollo.Apollo) {
448
- super(apollo);
449
- }
450
- }
451
- export const SubmitCommentDocument = gql`
452
- mutation submitComment($repoFullName: String!, $commentContent: String!) {
453
- submitComment(repoFullName: $repoFullName, commentContent: $commentContent) {
454
- ...CommentsPageComment
455
- }
456
- }
457
- ${CommentsPageCommentFragmentDoc}
458
- `;
459
-
460
- @Injectable({
461
- providedIn: 'root',
462
- })
463
- export class SubmitCommentGQL extends Apollo.Mutation<SubmitCommentMutation, SubmitCommentMutationVariables> {
464
- document = SubmitCommentDocument;
465
-
466
- constructor(apollo: Apollo.Apollo) {
467
- super(apollo);
468
- }
469
- }
470
- export const VoteDocument = gql`
471
- mutation vote($repoFullName: String!, $type: VoteType!) {
472
- vote(repoFullName: $repoFullName, type: $type) {
473
- score
474
- id
475
- vote {
476
- vote_value
477
- }
478
- }
479
- }
480
- `;
481
-
482
- @Injectable({
483
- providedIn: 'root',
484
- })
485
- export class VoteGQL extends Apollo.Mutation<VoteMutation, VoteMutationVariables> {
486
- document = VoteDocument;
487
-
488
- constructor(apollo: Apollo.Apollo) {
489
- super(apollo);
490
- }
491
- }