mirror of
https://github.com/captbaritone/webamp.git
synced 2026-07-17 16:46:04 +00:00
Upgrade Grats
This commit is contained in:
parent
a20bab1877
commit
6434ecc626
4 changed files with 38 additions and 53 deletions
|
|
@ -1,5 +1,6 @@
|
|||
# Schema generated by Grats (https://grats.capt.dev)
|
||||
# Do not manually edit. Regenerate by running `npx grats`.
|
||||
|
||||
"""
|
||||
Indicates that a position is semantically non null: it is only null if there is a matching error in the `errors` array.
|
||||
In all other cases, the position is non-null.
|
||||
|
|
|
|||
|
|
@ -2,8 +2,9 @@
|
|||
* Executable schema generated by Grats (https://grats.capt.dev)
|
||||
* Do not manually edit. Regenerate by running `npx grats`.
|
||||
*/
|
||||
import { defaultFieldResolver, GraphQLSchema, GraphQLObjectType, GraphQLString, GraphQLBoolean, GraphQLInt, GraphQLInterfaceType, GraphQLList, GraphQLNonNull, GraphQLID, GraphQLEnumType, GraphQLInputObjectType } from "graphql";
|
||||
import { getUserContext as getUserContext } from "./index";
|
||||
|
||||
import { GraphQLSchema, GraphQLDirective, DirectiveLocation, GraphQLList, GraphQLInt, specifiedDirectives, GraphQLObjectType, GraphQLString, GraphQLBoolean, GraphQLInterfaceType, GraphQLNonNull, GraphQLID, GraphQLEnumType, defaultFieldResolver, GraphQLInputObjectType } from "graphql";
|
||||
import { getUserContext } from "./index";
|
||||
import { fetch_archive_file_by_md5 as queryFetch_archive_file_by_md5Resolver } from "./../../data/ArchiveFileModel";
|
||||
import { fetch_internet_archive_item_by_identifier as queryFetch_internet_archive_item_by_identifierResolver } from "./../../data/IaItemModel";
|
||||
import { fetch_skin_by_md5 as queryFetch_skin_by_md5Resolver, search_classic_skins as querySearch_classic_skinsResolver, search_skins as querySearch_skinsResolver, skin_to_review as querySkin_to_reviewResolver } from "./resolvers/SkinResolver";
|
||||
|
|
@ -189,7 +190,6 @@ export function getSchema(): GraphQLSchema {
|
|||
args: {
|
||||
normalize_extension: {
|
||||
description: "If true, the the correct file extension (.wsz or .wal) will be .\nOtherwise, the original user-uploaded file extension will be used.",
|
||||
name: "normalize_extension",
|
||||
type: new GraphQLNonNull(GraphQLBoolean),
|
||||
defaultValue: false
|
||||
}
|
||||
|
|
@ -384,7 +384,6 @@ export function getSchema(): GraphQLSchema {
|
|||
args: {
|
||||
normalize_extension: {
|
||||
description: "If true, the the correct file extension (.wsz or .wal) will be .\nOtherwise, the original user-uploaded file extension will be used.",
|
||||
name: "normalize_extension",
|
||||
type: new GraphQLNonNull(GraphQLBoolean),
|
||||
defaultValue: false
|
||||
}
|
||||
|
|
@ -547,7 +546,6 @@ export function getSchema(): GraphQLSchema {
|
|||
args: {
|
||||
normalize_extension: {
|
||||
description: "If true, the the correct file extension (.wsz or .wal) will be .\nOtherwise, the original user-uploaded file extension will be used.",
|
||||
name: "normalize_extension",
|
||||
type: new GraphQLNonNull(GraphQLBoolean),
|
||||
defaultValue: false
|
||||
}
|
||||
|
|
@ -909,7 +907,6 @@ export function getSchema(): GraphQLSchema {
|
|||
type: ArchiveFileType,
|
||||
args: {
|
||||
md5: {
|
||||
name: "md5",
|
||||
type: new GraphQLNonNull(GraphQLString)
|
||||
}
|
||||
},
|
||||
|
|
@ -923,7 +920,6 @@ export function getSchema(): GraphQLSchema {
|
|||
type: InternetArchiveItemType,
|
||||
args: {
|
||||
identifier: {
|
||||
name: "identifier",
|
||||
type: new GraphQLNonNull(GraphQLString)
|
||||
}
|
||||
},
|
||||
|
|
@ -937,7 +933,6 @@ export function getSchema(): GraphQLSchema {
|
|||
type: SkinType,
|
||||
args: {
|
||||
md5: {
|
||||
name: "md5",
|
||||
type: new GraphQLNonNull(GraphQLString)
|
||||
}
|
||||
},
|
||||
|
|
@ -951,7 +946,6 @@ export function getSchema(): GraphQLSchema {
|
|||
type: TweetType,
|
||||
args: {
|
||||
url: {
|
||||
name: "url",
|
||||
type: new GraphQLNonNull(GraphQLString)
|
||||
}
|
||||
},
|
||||
|
|
@ -973,12 +967,10 @@ export function getSchema(): GraphQLSchema {
|
|||
type: ModernSkinsConnectionType,
|
||||
args: {
|
||||
first: {
|
||||
name: "first",
|
||||
type: new GraphQLNonNull(GraphQLInt),
|
||||
defaultValue: 10
|
||||
},
|
||||
offset: {
|
||||
name: "offset",
|
||||
type: new GraphQLNonNull(GraphQLInt),
|
||||
defaultValue: 0
|
||||
}
|
||||
|
|
@ -993,7 +985,6 @@ export function getSchema(): GraphQLSchema {
|
|||
type: NodeType,
|
||||
args: {
|
||||
id: {
|
||||
name: "id",
|
||||
type: new GraphQLNonNull(GraphQLID)
|
||||
}
|
||||
},
|
||||
|
|
@ -1007,17 +998,14 @@ export function getSchema(): GraphQLSchema {
|
|||
type: new GraphQLList(ClassicSkinType),
|
||||
args: {
|
||||
first: {
|
||||
name: "first",
|
||||
type: new GraphQLNonNull(GraphQLInt),
|
||||
defaultValue: 10
|
||||
},
|
||||
offset: {
|
||||
name: "offset",
|
||||
type: new GraphQLNonNull(GraphQLInt),
|
||||
defaultValue: 0
|
||||
},
|
||||
query: {
|
||||
name: "query",
|
||||
type: new GraphQLNonNull(GraphQLString)
|
||||
}
|
||||
},
|
||||
|
|
@ -1031,17 +1019,14 @@ export function getSchema(): GraphQLSchema {
|
|||
type: new GraphQLList(SkinType),
|
||||
args: {
|
||||
first: {
|
||||
name: "first",
|
||||
type: new GraphQLNonNull(GraphQLInt),
|
||||
defaultValue: 10
|
||||
},
|
||||
offset: {
|
||||
name: "offset",
|
||||
type: new GraphQLNonNull(GraphQLInt),
|
||||
defaultValue: 0
|
||||
},
|
||||
query: {
|
||||
name: "query",
|
||||
type: new GraphQLNonNull(GraphQLString)
|
||||
}
|
||||
},
|
||||
|
|
@ -1063,21 +1048,17 @@ export function getSchema(): GraphQLSchema {
|
|||
type: SkinsConnectionType,
|
||||
args: {
|
||||
filter: {
|
||||
name: "filter",
|
||||
type: SkinsFilterOptionType
|
||||
},
|
||||
first: {
|
||||
name: "first",
|
||||
type: new GraphQLNonNull(GraphQLInt),
|
||||
defaultValue: 10
|
||||
},
|
||||
offset: {
|
||||
name: "offset",
|
||||
type: new GraphQLNonNull(GraphQLInt),
|
||||
defaultValue: 0
|
||||
},
|
||||
sort: {
|
||||
name: "sort",
|
||||
type: SkinsSortOptionType
|
||||
}
|
||||
},
|
||||
|
|
@ -1099,17 +1080,14 @@ export function getSchema(): GraphQLSchema {
|
|||
type: TweetsConnectionType,
|
||||
args: {
|
||||
first: {
|
||||
name: "first",
|
||||
type: new GraphQLNonNull(GraphQLInt),
|
||||
defaultValue: 10
|
||||
},
|
||||
offset: {
|
||||
name: "offset",
|
||||
type: new GraphQLNonNull(GraphQLInt),
|
||||
defaultValue: 0
|
||||
},
|
||||
sort: {
|
||||
name: "sort",
|
||||
type: TweetsSortOptionType
|
||||
}
|
||||
},
|
||||
|
|
@ -1123,7 +1101,6 @@ export function getSchema(): GraphQLSchema {
|
|||
type: new GraphQLList(SkinUploadType),
|
||||
args: {
|
||||
ids: {
|
||||
name: "ids",
|
||||
type: new GraphQLNonNull(new GraphQLList(new GraphQLNonNull(GraphQLString)))
|
||||
}
|
||||
},
|
||||
|
|
@ -1138,7 +1115,6 @@ export function getSchema(): GraphQLSchema {
|
|||
type: new GraphQLList(SkinUploadType),
|
||||
args: {
|
||||
md5s: {
|
||||
name: "md5s",
|
||||
type: new GraphQLNonNull(new GraphQLList(new GraphQLNonNull(GraphQLString)))
|
||||
}
|
||||
},
|
||||
|
|
@ -1205,7 +1181,6 @@ export function getSchema(): GraphQLSchema {
|
|||
type: new GraphQLList(UploadUrlType),
|
||||
args: {
|
||||
files: {
|
||||
name: "files",
|
||||
type: new GraphQLNonNull(new GraphQLList(new GraphQLNonNull(UploadUrlRequestType)))
|
||||
}
|
||||
},
|
||||
|
|
@ -1219,11 +1194,9 @@ export function getSchema(): GraphQLSchema {
|
|||
type: GraphQLBoolean,
|
||||
args: {
|
||||
id: {
|
||||
name: "id",
|
||||
type: new GraphQLNonNull(GraphQLString)
|
||||
},
|
||||
md5: {
|
||||
name: "md5",
|
||||
type: new GraphQLNonNull(GraphQLString)
|
||||
}
|
||||
},
|
||||
|
|
@ -1244,7 +1217,6 @@ export function getSchema(): GraphQLSchema {
|
|||
type: GraphQLBoolean,
|
||||
args: {
|
||||
md5: {
|
||||
name: "md5",
|
||||
type: new GraphQLNonNull(GraphQLString)
|
||||
}
|
||||
},
|
||||
|
|
@ -1258,7 +1230,6 @@ export function getSchema(): GraphQLSchema {
|
|||
type: GraphQLBoolean,
|
||||
args: {
|
||||
md5: {
|
||||
name: "md5",
|
||||
type: new GraphQLNonNull(GraphQLString)
|
||||
}
|
||||
},
|
||||
|
|
@ -1272,7 +1243,6 @@ export function getSchema(): GraphQLSchema {
|
|||
type: GraphQLBoolean,
|
||||
args: {
|
||||
md5: {
|
||||
name: "md5",
|
||||
type: new GraphQLNonNull(GraphQLString)
|
||||
}
|
||||
},
|
||||
|
|
@ -1286,7 +1256,6 @@ export function getSchema(): GraphQLSchema {
|
|||
type: GraphQLBoolean,
|
||||
args: {
|
||||
md5: {
|
||||
name: "md5",
|
||||
type: new GraphQLNonNull(GraphQLString)
|
||||
}
|
||||
},
|
||||
|
|
@ -1300,15 +1269,12 @@ export function getSchema(): GraphQLSchema {
|
|||
type: GraphQLBoolean,
|
||||
args: {
|
||||
email: {
|
||||
name: "email",
|
||||
type: GraphQLString
|
||||
},
|
||||
message: {
|
||||
name: "message",
|
||||
type: new GraphQLNonNull(GraphQLString)
|
||||
},
|
||||
url: {
|
||||
name: "url",
|
||||
type: GraphQLString
|
||||
}
|
||||
},
|
||||
|
|
@ -1328,6 +1294,17 @@ export function getSchema(): GraphQLSchema {
|
|||
}
|
||||
});
|
||||
return new GraphQLSchema({
|
||||
directives: [...specifiedDirectives, new GraphQLDirective({
|
||||
name: "semanticNonNull",
|
||||
locations: [DirectiveLocation.FIELD_DEFINITION],
|
||||
description: "Indicates that a position is semantically non null: it is only null if there is a matching error in the `errors` array.\nIn all other cases, the position is non-null.\n\nTools doing code generation may use this information to generate the position as non-null if field errors are handled out of band:\n\n```graphql\ntype User {\n # email is semantically non-null and can be generated as non-null by error-handling clients.\n email: String @semanticNonNull\n}\n```\n\nThe `levels` argument indicates what levels are semantically non null in case of lists:\n\n```graphql\ntype User {\n # friends is semantically non null\n friends: [User] @semanticNonNull # same as @semanticNonNull(levels: [0])\n\n # every friends[k] is semantically non null\n friends: [User] @semanticNonNull(levels: [1])\n\n # friends as well as every friends[k] is semantically non null\n friends: [User] @semanticNonNull(levels: [0, 1])\n}\n```\n\n`levels` are zero indexed.\nPassing a negative level or a level greater than the list dimension is an error.",
|
||||
args: {
|
||||
levels: {
|
||||
type: new GraphQLList(GraphQLInt),
|
||||
defaultValue: [0]
|
||||
}
|
||||
}
|
||||
})],
|
||||
query: QueryType,
|
||||
mutation: MutationType,
|
||||
types: [RatingType, SkinUploadStatusType, SkinsFilterOptionType, SkinsSortOptionType, TweetsSortOptionType, NodeType, SkinType, UploadUrlRequestType, ArchiveFileType, ClassicSkinType, DatabaseStatisticsType, InternetArchiveItemType, ModernSkinType, ModernSkinsConnectionType, MutationType, QueryType, ReviewType, SkinUploadType, SkinsConnectionType, TweetType, TweetsConnectionType, UploadMutationsType, UploadUrlType, UserType]
|
||||
|
|
|
|||
|
|
@ -75,7 +75,7 @@
|
|||
"@types/node-fetch": "^2.5.7",
|
||||
"@typescript-eslint/eslint-plugin": "^8.36.0",
|
||||
"@typescript-eslint/parser": "^8.36.0",
|
||||
"grats": "^0.0.31",
|
||||
"grats": "0.0.0-main-e655d1ae",
|
||||
"typescript": "^5.6.2"
|
||||
},
|
||||
"jest": {
|
||||
|
|
|
|||
37
pnpm-lock.yaml
generated
37
pnpm-lock.yaml
generated
|
|
@ -279,8 +279,8 @@ importers:
|
|||
specifier: ^8.36.0
|
||||
version: 8.36.0(eslint@8.57.0)(typescript@5.6.3)
|
||||
grats:
|
||||
specifier: ^0.0.31
|
||||
version: 0.0.31
|
||||
specifier: 0.0.0-main-e655d1ae
|
||||
version: 0.0.0-main-e655d1ae
|
||||
typescript:
|
||||
specifier: ^5.6.2
|
||||
version: 5.6.3
|
||||
|
|
@ -5303,6 +5303,10 @@ packages:
|
|||
resolution: {integrity: sha512-y4Mg2tXshplEbSGzx7amzPwKKOCGuoSRP/CjEdwwk0FOGlUbq6lKuoyDZTNZkmxHdJtp54hdfY/JUrdL7Xfdug==}
|
||||
engines: {node: '>=14'}
|
||||
|
||||
commander@14.0.1:
|
||||
resolution: {integrity: sha512-2JkV3gUZUVrbNA+1sjBOYLsMZ5cEEl8GTFP2a4AVz5hvasAMCQ1D2l2le/cX+pV4N6ZU17zjUahLpIXRrnWL8A==}
|
||||
engines: {node: '>=20'}
|
||||
|
||||
commander@2.20.3:
|
||||
resolution: {integrity: sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==}
|
||||
|
||||
|
|
@ -7367,9 +7371,9 @@ packages:
|
|||
resolution: {integrity: sha512-59LZHPdGZVh695Ud9lRzPBVTtlX9ZCV150Er2W43ro37wVof0ctenSaskPPjN7lVTIN8mSZt8PHUNKZuNQUuxw==}
|
||||
engines: {node: ^12.22.0 || ^14.16.0 || ^16.0.0 || >=17.0.0}
|
||||
|
||||
grats@0.0.31:
|
||||
resolution: {integrity: sha512-nTxRZYWgi+s8xj06QfcqtZ4nReXKyZhYHd9+9pLLthorvBSr4hbHBdl5L9HpHBqaxatWx98I6wdS5+8c+FQuxA==}
|
||||
engines: {node: '>=16 <=21', pnpm: '>=8 <=9'}
|
||||
grats@0.0.0-main-e655d1ae:
|
||||
resolution: {integrity: sha512-ZMMY7nVosPMTagAakS3BeenmBZrEzIryPm0hmsDf20CdlCBhOwiiiIXV4I/fcYXCPI0vng1Ns6c2i+OftFTYBQ==}
|
||||
engines: {node: '>=16 <=23'}
|
||||
hasBin: true
|
||||
|
||||
gray-matter@4.0.3:
|
||||
|
|
@ -9610,6 +9614,7 @@ packages:
|
|||
node-domexception@1.0.0:
|
||||
resolution: {integrity: sha512-/jKZoMpw0F8GRwl4/eLROPA3cfcXtLApP0QzLmUT/HuPCZWyB7IY9ZrMeKw2O/nFIqPQB3PVM9aYm0F312AXDQ==}
|
||||
engines: {node: '>=10.5.0'}
|
||||
deprecated: Use your platform's native DOMException instead
|
||||
|
||||
node-emoji@2.2.0:
|
||||
resolution: {integrity: sha512-Z3lTE9pLaJF47NyMhd4ww1yFTAP8YhYI8SleJiHzM46Fgpm5cnNzSl9XfzFNqbaz+VlJrIj3fXQ4DeN1Rjm6cw==}
|
||||
|
|
@ -12788,11 +12793,6 @@ packages:
|
|||
engines: {node: '>=4.2.0'}
|
||||
hasBin: true
|
||||
|
||||
typescript@5.5.4:
|
||||
resolution: {integrity: sha512-Mtq29sKDAEYP7aljRgtPOpTvOfbwRWlS6dPRzwjdE+C0R4brX/GUyhHSecbHMFLNBLcJIPt9nl9yG5TZ1weH+Q==}
|
||||
engines: {node: '>=14.17'}
|
||||
hasBin: true
|
||||
|
||||
typescript@5.6.3:
|
||||
resolution: {integrity: sha512-hjcS1mhfuyi4WW8IWtjP7brDrG2cuDZukyrYrSauoXGNgx0S7zceP07adYkJycEr56BOUTNPzbInooiN3fn1qw==}
|
||||
engines: {node: '>=14.17'}
|
||||
|
|
@ -12803,6 +12803,11 @@ packages:
|
|||
engines: {node: '>=14.17'}
|
||||
hasBin: true
|
||||
|
||||
typescript@5.9.2:
|
||||
resolution: {integrity: sha512-CWBzXQrc/qOkhidw1OzBTQuYRbfyxDXJMVJ1XNwUHGROVmuaeiEm3OslpZ1RV96d7SKKjZKrSJu3+t/xlw3R9A==}
|
||||
engines: {node: '>=14.17'}
|
||||
hasBin: true
|
||||
|
||||
ufo@1.5.3:
|
||||
resolution: {integrity: sha512-Y7HYmWaFwPUmkoQCUIAYpKqkOf+SbVj/2fJJZ4RJMCfZp0rTGwRbzQD+HghfnhKOjL9E01okqz+ncJskGYfBNw==}
|
||||
|
||||
|
|
@ -19320,6 +19325,8 @@ snapshots:
|
|||
|
||||
commander@10.0.1: {}
|
||||
|
||||
commander@14.0.1: {}
|
||||
|
||||
commander@2.20.3: {}
|
||||
|
||||
commander@4.1.1: {}
|
||||
|
|
@ -21876,12 +21883,12 @@ snapshots:
|
|||
|
||||
graphql@16.8.1: {}
|
||||
|
||||
grats@0.0.31:
|
||||
grats@0.0.0-main-e655d1ae:
|
||||
dependencies:
|
||||
commander: 10.0.1
|
||||
commander: 14.0.1
|
||||
graphql: 16.11.0
|
||||
semver: 7.7.2
|
||||
typescript: 5.5.4
|
||||
typescript: 5.9.2
|
||||
|
||||
gray-matter@4.0.3:
|
||||
dependencies:
|
||||
|
|
@ -28716,12 +28723,12 @@ snapshots:
|
|||
|
||||
typescript@4.3.4: {}
|
||||
|
||||
typescript@5.5.4: {}
|
||||
|
||||
typescript@5.6.3: {}
|
||||
|
||||
typescript@5.8.3: {}
|
||||
|
||||
typescript@5.9.2: {}
|
||||
|
||||
ufo@1.5.3: {}
|
||||
|
||||
uint8array-extras@1.4.0: {}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue