@kubb/plugin-react-query 3.1.0 → 3.2.0
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.
- package/dist/{chunk-YGWYQQ6H.js → chunk-5NA5VRXZ.js} +78 -47
- package/dist/chunk-5NA5VRXZ.js.map +1 -0
- package/dist/{chunk-GMONUHPD.js → chunk-A24GQ5ZN.js} +18 -3
- package/dist/chunk-A24GQ5ZN.js.map +1 -0
- package/dist/{chunk-WOYQTGDC.cjs → chunk-EZXV6KB3.cjs} +78 -47
- package/dist/chunk-EZXV6KB3.cjs.map +1 -0
- package/dist/{chunk-PBJIUPCN.cjs → chunk-VWLT4KLD.cjs} +33 -18
- package/dist/chunk-VWLT4KLD.cjs.map +1 -0
- package/dist/components.cjs +9 -9
- package/dist/components.d.cts +29 -15
- package/dist/components.d.ts +29 -15
- package/dist/components.js +1 -1
- package/dist/generators.cjs +6 -6
- package/dist/generators.d.cts +1 -1
- package/dist/generators.d.ts +1 -1
- package/dist/generators.js +2 -2
- package/dist/index.cjs +7 -5
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +5 -3
- package/dist/index.js.map +1 -1
- package/dist/{types-BBt81Oun.d.cts → types-ClmUaz7P.d.cts} +13 -0
- package/dist/{types-BBt81Oun.d.ts → types-ClmUaz7P.d.ts} +13 -0
- package/package.json +11 -11
- package/src/components/InfiniteQuery.tsx +9 -3
- package/src/components/InfiniteQueryOptions.tsx +9 -4
- package/src/components/Mutation.tsx +18 -4
- package/src/components/MutationKey.tsx +5 -4
- package/src/components/Query.tsx +9 -3
- package/src/components/QueryKey.tsx +9 -6
- package/src/components/QueryOptions.tsx +9 -5
- package/src/components/SuspenseQuery.tsx +9 -3
- package/src/generators/__snapshots__/clientPostImportPath.ts +4 -4
- package/src/generators/__snapshots__/getPetIdCamelCase.ts +52 -0
- package/src/generators/__snapshots__/postAsQuery.ts +4 -4
- package/src/generators/__snapshots__/updatePetById.ts +4 -4
- package/src/generators/__snapshots__/updatePetByIdPathParamsObject.ts +4 -4
- package/src/generators/infiniteQueryGenerator.tsx +4 -0
- package/src/generators/mutationGenerator.tsx +3 -0
- package/src/generators/queryGenerator.tsx +4 -0
- package/src/generators/suspenseQueryGenerator.tsx +4 -0
- package/src/plugin.ts +2 -0
- package/src/types.ts +7 -0
- package/dist/chunk-GMONUHPD.js.map +0 -1
- package/dist/chunk-PBJIUPCN.cjs.map +0 -1
- package/dist/chunk-WOYQTGDC.cjs.map +0 -1
- package/dist/chunk-YGWYQQ6H.js.map +0 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { QueryKey, Client, QueryOptions, Query, MutationKey, Mutation, InfiniteQueryOptions, InfiniteQuery, SuspenseQuery } from './chunk-
|
|
1
|
+
import { QueryKey, Client, QueryOptions, Query, MutationKey, Mutation, InfiniteQueryOptions, InfiniteQuery, SuspenseQuery } from './chunk-5NA5VRXZ.js';
|
|
2
2
|
import { createReactGenerator } from '@kubb/plugin-oas';
|
|
3
3
|
import { useOperationManager } from '@kubb/plugin-oas/hooks';
|
|
4
4
|
import { pluginTsName } from '@kubb/plugin-ts';
|
|
@@ -77,6 +77,7 @@ var queryGenerator = createReactGenerator({
|
|
|
77
77
|
operation,
|
|
78
78
|
pathParamsType: options.pathParamsType,
|
|
79
79
|
typeSchemas: type.schemas,
|
|
80
|
+
paramsCasing: options.paramsCasing,
|
|
80
81
|
transformer: options.queryKey
|
|
81
82
|
}
|
|
82
83
|
),
|
|
@@ -92,6 +93,7 @@ var queryGenerator = createReactGenerator({
|
|
|
92
93
|
zodSchemas: zod.schemas,
|
|
93
94
|
dataReturnType: options.client.dataReturnType,
|
|
94
95
|
paramsType: options.paramsType,
|
|
96
|
+
paramsCasing: options.paramsCasing,
|
|
95
97
|
pathParamsType: options.pathParamsType,
|
|
96
98
|
parser: options.parser
|
|
97
99
|
}
|
|
@@ -104,6 +106,7 @@ var queryGenerator = createReactGenerator({
|
|
|
104
106
|
clientName: client.name,
|
|
105
107
|
queryKeyName: queryKey.name,
|
|
106
108
|
typeSchemas: type.schemas,
|
|
109
|
+
paramsCasing: options.paramsCasing,
|
|
107
110
|
paramsType: options.paramsType,
|
|
108
111
|
pathParamsType: options.pathParamsType
|
|
109
112
|
}
|
|
@@ -117,6 +120,7 @@ var queryGenerator = createReactGenerator({
|
|
|
117
120
|
name: query.name,
|
|
118
121
|
queryOptionsName: queryOptions.name,
|
|
119
122
|
typeSchemas: type.schemas,
|
|
123
|
+
paramsCasing: options.paramsCasing,
|
|
120
124
|
paramsType: options.paramsType,
|
|
121
125
|
pathParamsType: options.pathParamsType,
|
|
122
126
|
operation,
|
|
@@ -193,6 +197,7 @@ var mutationGenerator = createReactGenerator({
|
|
|
193
197
|
operation,
|
|
194
198
|
pathParamsType: options.pathParamsType,
|
|
195
199
|
typeSchemas: type.schemas,
|
|
200
|
+
paramsCasing: options.paramsCasing,
|
|
196
201
|
transformer: options.mutationKey
|
|
197
202
|
}
|
|
198
203
|
),
|
|
@@ -207,6 +212,7 @@ var mutationGenerator = createReactGenerator({
|
|
|
207
212
|
typeSchemas: type.schemas,
|
|
208
213
|
zodSchemas: zod.schemas,
|
|
209
214
|
dataReturnType: options.client.dataReturnType,
|
|
215
|
+
paramsCasing: options.paramsCasing,
|
|
210
216
|
paramsType: options.paramsType,
|
|
211
217
|
pathParamsType: options.pathParamsType,
|
|
212
218
|
parser: options.parser
|
|
@@ -224,6 +230,7 @@ var mutationGenerator = createReactGenerator({
|
|
|
224
230
|
typeSchemas: type.schemas,
|
|
225
231
|
operation,
|
|
226
232
|
dataReturnType: options.client.dataReturnType,
|
|
233
|
+
paramsCasing: options.paramsCasing,
|
|
227
234
|
paramsType: options.paramsType,
|
|
228
235
|
pathParamsType: options.pathParamsType,
|
|
229
236
|
mutationKeyName: mutationKey.name
|
|
@@ -302,6 +309,7 @@ var infiniteQueryGenerator = createReactGenerator({
|
|
|
302
309
|
name: queryKey.name,
|
|
303
310
|
typeName: queryKey.typeName,
|
|
304
311
|
operation,
|
|
312
|
+
paramsCasing: options.paramsCasing,
|
|
305
313
|
pathParamsType: options.pathParamsType,
|
|
306
314
|
typeSchemas: type.schemas,
|
|
307
315
|
transformer: options.queryKey
|
|
@@ -318,6 +326,7 @@ var infiniteQueryGenerator = createReactGenerator({
|
|
|
318
326
|
typeSchemas: type.schemas,
|
|
319
327
|
zodSchemas: zod.schemas,
|
|
320
328
|
dataReturnType: options.client.dataReturnType,
|
|
329
|
+
paramsCasing: options.paramsCasing,
|
|
321
330
|
paramsType: options.paramsType,
|
|
322
331
|
pathParamsType: options.pathParamsType,
|
|
323
332
|
parser: options.parser
|
|
@@ -333,6 +342,7 @@ var infiniteQueryGenerator = createReactGenerator({
|
|
|
333
342
|
clientName: client.name,
|
|
334
343
|
queryKeyName: queryKey.name,
|
|
335
344
|
typeSchemas: type.schemas,
|
|
345
|
+
paramsCasing: options.paramsCasing,
|
|
336
346
|
paramsType: options.paramsType,
|
|
337
347
|
pathParamsType: options.pathParamsType,
|
|
338
348
|
dataReturnType: options.client.dataReturnType,
|
|
@@ -351,6 +361,7 @@ var infiniteQueryGenerator = createReactGenerator({
|
|
|
351
361
|
name: query.name,
|
|
352
362
|
queryOptionsName: queryOptions.name,
|
|
353
363
|
typeSchemas: type.schemas,
|
|
364
|
+
paramsCasing: options.paramsCasing,
|
|
354
365
|
paramsType: options.paramsType,
|
|
355
366
|
pathParamsType: options.pathParamsType,
|
|
356
367
|
operation,
|
|
@@ -432,6 +443,7 @@ var suspenseQueryGenerator = createReactGenerator({
|
|
|
432
443
|
name: queryKey.name,
|
|
433
444
|
typeName: queryKey.typeName,
|
|
434
445
|
operation,
|
|
446
|
+
paramsCasing: options.paramsCasing,
|
|
435
447
|
pathParamsType: options.pathParamsType,
|
|
436
448
|
typeSchemas: type.schemas,
|
|
437
449
|
transformer: options.queryKey
|
|
@@ -448,6 +460,7 @@ var suspenseQueryGenerator = createReactGenerator({
|
|
|
448
460
|
typeSchemas: type.schemas,
|
|
449
461
|
zodSchemas: zod.schemas,
|
|
450
462
|
dataReturnType: options.client.dataReturnType,
|
|
463
|
+
paramsCasing: options.paramsCasing,
|
|
451
464
|
paramsType: options.paramsType,
|
|
452
465
|
pathParamsType: options.pathParamsType,
|
|
453
466
|
parser: options.parser
|
|
@@ -461,6 +474,7 @@ var suspenseQueryGenerator = createReactGenerator({
|
|
|
461
474
|
clientName: client.name,
|
|
462
475
|
queryKeyName: queryKey.name,
|
|
463
476
|
typeSchemas: type.schemas,
|
|
477
|
+
paramsCasing: options.paramsCasing,
|
|
464
478
|
paramsType: options.paramsType,
|
|
465
479
|
pathParamsType: options.pathParamsType
|
|
466
480
|
}
|
|
@@ -475,6 +489,7 @@ var suspenseQueryGenerator = createReactGenerator({
|
|
|
475
489
|
queryOptionsName: queryOptions.name,
|
|
476
490
|
typeSchemas: type.schemas,
|
|
477
491
|
paramsType: options.paramsType,
|
|
492
|
+
paramsCasing: options.paramsCasing,
|
|
478
493
|
pathParamsType: options.pathParamsType,
|
|
479
494
|
operation,
|
|
480
495
|
dataReturnType: options.client.dataReturnType,
|
|
@@ -488,5 +503,5 @@ var suspenseQueryGenerator = createReactGenerator({
|
|
|
488
503
|
});
|
|
489
504
|
|
|
490
505
|
export { infiniteQueryGenerator, mutationGenerator, queryGenerator, suspenseQueryGenerator };
|
|
491
|
-
//# sourceMappingURL=chunk-
|
|
492
|
-
//# sourceMappingURL=chunk-
|
|
506
|
+
//# sourceMappingURL=chunk-A24GQ5ZN.js.map
|
|
507
|
+
//# sourceMappingURL=chunk-A24GQ5ZN.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/generators/queryGenerator.tsx","../src/generators/mutationGenerator.tsx","../src/generators/infiniteQueryGenerator.tsx","../src/generators/suspenseQueryGenerator.tsx"],"names":["createReactGenerator","useApp","useOperationManager","difference","pluginTsName","pluginZodName","jsxs","File","jsx","Fragment"],"mappings":";;;;;;;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AAAA,UACnB,cAAc,QAAS,CAAA,IAAA;AAAA,UACvB,aAAa,IAAK,CAAA,OAAA;AAAA,UAClB,cAAc,OAAQ,CAAA,YAAA;AAAA,UACtB,YAAY,OAAQ,CAAA,UAAA;AAAA,UACpB,gBAAgB,OAAQ,CAAA;AAAA;AAAA,OAC1B;AAAA,MACC,OAAQ,CAAA,QAAA,oBACPF,IAAAA,CAAAG,UAAA,EACE,QAAA,EAAA;AAAA,wBAAAD,GAAAA,CAACD,KAAK,MAAL,EAAA,EAAY,MAAM,CAAC,kBAAkB,CAAG,EAAA,IAAA,EAAM,UAAY,EAAA,CAAA;AAAA,wBAC3DC,GAAAA,CAACD,IAAK,CAAA,MAAA,EAAL,EAAY,IAAM,EAAA,CAAC,UAAY,EAAA,yBAAA,EAA2B,wBAAwB,CAAA,EAAG,IAAM,EAAA,UAAA,EAAY,YAAU,IAAC,EAAA,CAAA;AAAA,wBACnHC,GAAAA;AAAA,UAAC,aAAA;AAAA,UAAA;AAAA,YACC,MAAM,KAAM,CAAA,IAAA;AAAA,YACZ,kBAAkB,YAAa,CAAA,IAAA;AAAA,YAC/B,aAAa,IAAK,CAAA,OAAA;AAAA,YAClB,YAAY,OAAQ,CAAA,UAAA;AAAA,YACpB,cAAc,OAAQ,CAAA,YAAA;AAAA,YACtB,gBAAgB,OAAQ,CAAA,cAAA;AAAA,YACxB,SAAA;AAAA,YACA,cAAA,EAAgB,QAAQ,MAAO,CAAA,cAAA;AAAA,YAC/B,cAAc,QAAS,CAAA,IAAA;AAAA,YACvB,kBAAkB,QAAS,CAAA;AAAA;AAAA;AAC7B,OACF,EAAA;AAAA,KAEJ,EAAA,CAAA;AAAA;AAGN,CAAC","file":"chunk-A24GQ5ZN.js","sourcesContent":["import { pluginClientName } from '@kubb/plugin-client'\nimport { Client } from '@kubb/plugin-client/components'\nimport { createReactGenerator } from '@kubb/plugin-oas'\nimport { useOperationManager } from '@kubb/plugin-oas/hooks'\nimport { pluginTsName } from '@kubb/plugin-ts'\nimport { pluginZodName } from '@kubb/plugin-zod'\nimport { File, useApp } from '@kubb/react'\nimport { difference } from 'remeda'\nimport { Query, QueryKey, QueryOptions } from '../components'\nimport type { PluginReactQuery } from '../types'\n\nexport const queryGenerator = createReactGenerator<PluginReactQuery>({\n name: 'react-query',\n Operation({ options, operation }) {\n const {\n plugin: {\n options: { output },\n },\n } = useApp<PluginReactQuery>()\n const { getSchemas, getName, getFile } = useOperationManager()\n\n const isQuery = typeof options.query === 'boolean' ? true : options.query?.methods.some((method) => operation.method === method)\n const isMutation = difference(options.mutation ? options.mutation.methods : [], options.query ? options.query.methods : []).some(\n (method) => operation.method === method,\n )\n\n const importPath = options.query ? options.query.importPath : '@tanstack/react-query'\n\n const query = {\n name: getName(operation, { type: 'function', prefix: 'use' }),\n typeName: getName(operation, { type: 'type' }),\n file: getFile(operation, { prefix: 'use' }),\n }\n\n const client = {\n name: getName(operation, { type: 'function' }),\n }\n\n const queryOptions = {\n name: getName(operation, { type: 'function', suffix: 'QueryOptions' }),\n }\n\n const queryKey = {\n name: getName(operation, { type: 'const', suffix: 'QueryKey' }),\n typeName: getName(operation, { type: 'type', suffix: 'QueryKey' }),\n }\n\n const type = {\n file: getFile(operation, { pluginKey: [pluginTsName] }),\n //todo remove type?\n schemas: getSchemas(operation, { pluginKey: [pluginTsName], type: 'type' }),\n }\n\n const zod = {\n file: getFile(operation, { pluginKey: [pluginZodName] }),\n schemas: getSchemas(operation, { pluginKey: [pluginZodName], type: 'function' }),\n }\n\n if (!isQuery || isMutation) {\n return null\n }\n\n return (\n <File baseName={query.file.baseName} path={query.file.path} meta={query.file.meta} banner={output?.banner} footer={output?.footer}>\n {options.parser === 'zod' && <File.Import name={[zod.schemas.response.name]} root={query.file.path} path={zod.file.path} />}\n <File.Import name={'client'} path={options.client.importPath} />\n <File.Import name={['RequestConfig']} path={options.client.importPath} isTypeOnly />\n {options.client.dataReturnType === 'full' && <File.Import name={['ResponseConfig']} path={options.client.importPath} isTypeOnly />}\n <File.Import\n name={[\n type.schemas.request?.name,\n type.schemas.response.name,\n type.schemas.pathParams?.name,\n type.schemas.queryParams?.name,\n type.schemas.headerParams?.name,\n ...(type.schemas.statusCodes?.map((item) => item.name) || []),\n ].filter(Boolean)}\n root={query.file.path}\n path={type.file.path}\n isTypeOnly\n />\n <QueryKey\n name={queryKey.name}\n typeName={queryKey.typeName}\n operation={operation}\n pathParamsType={options.pathParamsType}\n typeSchemas={type.schemas}\n paramsCasing={options.paramsCasing}\n transformer={options.queryKey}\n />\n <Client\n name={client.name}\n isExportable={false}\n isIndexable={false}\n baseURL={options.client.baseURL}\n operation={operation}\n typeSchemas={type.schemas}\n zodSchemas={zod.schemas}\n dataReturnType={options.client.dataReturnType}\n paramsType={options.paramsType}\n paramsCasing={options.paramsCasing}\n pathParamsType={options.pathParamsType}\n parser={options.parser}\n />\n <File.Import name={['queryOptions']} path={importPath} />\n <QueryOptions\n name={queryOptions.name}\n clientName={client.name}\n queryKeyName={queryKey.name}\n typeSchemas={type.schemas}\n paramsCasing={options.paramsCasing}\n paramsType={options.paramsType}\n pathParamsType={options.pathParamsType}\n />\n {options.query && (\n <>\n <File.Import name={['useQuery']} path={importPath} />\n <File.Import name={['QueryKey', 'QueryObserverOptions', 'UseQueryResult']} path={importPath} isTypeOnly />\n <Query\n name={query.name}\n queryOptionsName={queryOptions.name}\n typeSchemas={type.schemas}\n paramsCasing={options.paramsCasing}\n paramsType={options.paramsType}\n pathParamsType={options.pathParamsType}\n operation={operation}\n dataReturnType={options.client.dataReturnType}\n queryKeyName={queryKey.name}\n queryKeyTypeName={queryKey.typeName}\n />\n </>\n )}\n </File>\n )\n },\n})\n","import { pluginClientName } from '@kubb/plugin-client'\nimport { Client } from '@kubb/plugin-client/components'\nimport { createReactGenerator } from '@kubb/plugin-oas'\nimport { useOperationManager } from '@kubb/plugin-oas/hooks'\nimport { pluginTsName } from '@kubb/plugin-ts'\nimport { pluginZodName } from '@kubb/plugin-zod'\nimport { File, useApp } from '@kubb/react'\nimport { difference } from 'remeda'\nimport { Mutation, MutationKey } from '../components'\nimport type { PluginReactQuery } from '../types'\n\nexport const mutationGenerator = createReactGenerator<PluginReactQuery>({\n name: 'react-query',\n Operation({ options, operation }) {\n const {\n plugin: {\n options: { output },\n },\n } = useApp<PluginReactQuery>()\n const { getSchemas, getName, getFile } = useOperationManager()\n\n const isQuery = !!options.query && options.query?.methods.some((method) => operation.method === method)\n const isMutation =\n !isQuery &&\n difference(options.mutation ? options.mutation.methods : [], options.query ? options.query.methods : []).some((method) => operation.method === method)\n\n const importPath = options.mutation ? options.mutation.importPath : '@tanstack/react-query'\n\n const mutation = {\n name: getName(operation, { type: 'function', prefix: 'use' }),\n typeName: getName(operation, { type: 'type' }),\n file: getFile(operation, { prefix: 'use' }),\n }\n\n const type = {\n file: getFile(operation, { pluginKey: [pluginTsName] }),\n //todo remove type?\n schemas: getSchemas(operation, { pluginKey: [pluginTsName], type: 'type' }),\n }\n\n const zod = {\n file: getFile(operation, { pluginKey: [pluginZodName] }),\n schemas: getSchemas(operation, { pluginKey: [pluginZodName], type: 'function' }),\n }\n\n const client = {\n name: getName(operation, { type: 'function' }),\n }\n\n const mutationKey = {\n name: getName(operation, { type: 'const', suffix: 'MutationKey' }),\n typeName: getName(operation, { type: 'type', suffix: 'MutationKey' }),\n }\n\n if (!isMutation) {\n return null\n }\n\n return (\n <File baseName={mutation.file.baseName} path={mutation.file.path} meta={mutation.file.meta} banner={output?.banner} footer={output?.footer}>\n {options.parser === 'zod' && <File.Import name={[zod.schemas.response.name]} root={mutation.file.path} path={zod.file.path} />}\n <File.Import name={'client'} path={options.client.importPath} />\n <File.Import name={['RequestConfig', 'ResponseConfig']} path={options.client.importPath} isTypeOnly />\n <File.Import\n name={[\n type.schemas.request?.name,\n type.schemas.response.name,\n type.schemas.pathParams?.name,\n type.schemas.queryParams?.name,\n type.schemas.headerParams?.name,\n ...(type.schemas.statusCodes?.map((item) => item.name) || []),\n ].filter(Boolean)}\n root={mutation.file.path}\n path={type.file.path}\n isTypeOnly\n />\n\n <MutationKey\n name={mutationKey.name}\n typeName={mutationKey.typeName}\n operation={operation}\n pathParamsType={options.pathParamsType}\n typeSchemas={type.schemas}\n paramsCasing={options.paramsCasing}\n transformer={options.mutationKey}\n />\n\n <Client\n name={client.name}\n isExportable={false}\n isIndexable={false}\n baseURL={options.client.baseURL}\n operation={operation}\n typeSchemas={type.schemas}\n zodSchemas={zod.schemas}\n dataReturnType={options.client.dataReturnType}\n paramsCasing={options.paramsCasing}\n paramsType={options.paramsType}\n pathParamsType={options.pathParamsType}\n parser={options.parser}\n />\n {options.mutation && (\n <>\n <File.Import name={['useMutation']} path={importPath} />\n <File.Import name={['UseMutationOptions']} path={importPath} isTypeOnly />\n <Mutation\n name={mutation.name}\n clientName={client.name}\n typeName={mutation.typeName}\n typeSchemas={type.schemas}\n operation={operation}\n dataReturnType={options.client.dataReturnType}\n paramsCasing={options.paramsCasing}\n paramsType={options.paramsType}\n pathParamsType={options.pathParamsType}\n mutationKeyName={mutationKey.name}\n />\n </>\n )}\n </File>\n )\n },\n})\n","import { pluginClientName } from '@kubb/plugin-client'\nimport { Client } from '@kubb/plugin-client/components'\nimport { createReactGenerator } from '@kubb/plugin-oas'\nimport { useOperationManager } from '@kubb/plugin-oas/hooks'\nimport { pluginTsName } from '@kubb/plugin-ts'\nimport { pluginZodName } from '@kubb/plugin-zod'\nimport { File, useApp } from '@kubb/react'\nimport { difference } from 'remeda'\nimport { InfiniteQuery, InfiniteQueryOptions, QueryKey } from '../components'\nimport type { PluginReactQuery } from '../types'\n\nexport const infiniteQueryGenerator = createReactGenerator<PluginReactQuery>({\n name: 'react-infinite-query',\n Operation({ options, operation }) {\n const {\n plugin: {\n options: { output },\n },\n } = useApp<PluginReactQuery>()\n const { getSchemas, getName, getFile } = useOperationManager()\n\n const isQuery = typeof options.query === 'boolean' ? true : options.query?.methods.some((method) => operation.method === method)\n const isMutation = difference(options.mutation ? options.mutation.methods : [], options.query ? options.query.methods : []).some(\n (method) => operation.method === method,\n )\n const isInfinite = !!options.infinite\n\n const importPath = options.query ? options.query.importPath : '@tanstack/react-query'\n\n const query = {\n name: getName(operation, { type: 'function', prefix: 'use', suffix: 'infinite' }),\n typeName: getName(operation, { type: 'type' }),\n file: getFile(operation, { prefix: 'use', suffix: 'infinite' }),\n }\n\n const client = {\n name: getName(operation, { type: 'function' }),\n }\n\n const queryOptions = {\n name: getName(operation, { type: 'function', suffix: 'InfiniteQueryOptions' }),\n }\n\n const queryKey = {\n name: getName(operation, { type: 'const', suffix: 'InfiniteQueryKey' }),\n typeName: getName(operation, { type: 'type', suffix: 'InfiniteQueryKey' }),\n }\n\n const type = {\n file: getFile(operation, { pluginKey: [pluginTsName] }),\n //todo remove type?\n schemas: getSchemas(operation, { pluginKey: [pluginTsName], type: 'type' }),\n }\n\n const zod = {\n file: getFile(operation, { pluginKey: [pluginZodName] }),\n schemas: getSchemas(operation, { pluginKey: [pluginZodName], type: 'function' }),\n }\n\n if (!isQuery || isMutation || !isInfinite) {\n return null\n }\n\n return (\n <File baseName={query.file.baseName} path={query.file.path} meta={query.file.meta} banner={output?.banner} footer={output?.footer}>\n {options.parser === 'zod' && <File.Import name={[zod.schemas.response.name]} root={query.file.path} path={zod.file.path} />}\n <File.Import name={'client'} path={options.client.importPath} />\n <File.Import name={['RequestConfig']} path={options.client.importPath} isTypeOnly />\n {options.client.dataReturnType === 'full' && <File.Import name={['ResponseConfig']} path={options.client.importPath} isTypeOnly />}\n <File.Import\n name={[\n type.schemas.request?.name,\n type.schemas.response.name,\n type.schemas.pathParams?.name,\n type.schemas.queryParams?.name,\n type.schemas.headerParams?.name,\n ...(type.schemas.statusCodes?.map((item) => item.name) || []),\n ].filter(Boolean)}\n root={query.file.path}\n path={type.file.path}\n isTypeOnly\n />\n <QueryKey\n name={queryKey.name}\n typeName={queryKey.typeName}\n operation={operation}\n paramsCasing={options.paramsCasing}\n pathParamsType={options.pathParamsType}\n typeSchemas={type.schemas}\n transformer={options.queryKey}\n />\n <Client\n name={client.name}\n isExportable={false}\n isIndexable={false}\n baseURL={options.client.baseURL}\n operation={operation}\n typeSchemas={type.schemas}\n zodSchemas={zod.schemas}\n dataReturnType={options.client.dataReturnType}\n paramsCasing={options.paramsCasing}\n paramsType={options.paramsType}\n pathParamsType={options.pathParamsType}\n parser={options.parser}\n />\n {options.infinite && (\n <>\n <File.Import name={['InfiniteData']} isTypeOnly path={importPath} />\n <File.Import name={['infiniteQueryOptions']} path={importPath} />\n <InfiniteQueryOptions\n name={queryOptions.name}\n clientName={client.name}\n queryKeyName={queryKey.name}\n typeSchemas={type.schemas}\n paramsCasing={options.paramsCasing}\n paramsType={options.paramsType}\n pathParamsType={options.pathParamsType}\n dataReturnType={options.client.dataReturnType}\n cursorParam={options.infinite.cursorParam}\n initialPageParam={options.infinite.initialPageParam}\n queryParam={options.infinite.queryParam}\n />\n </>\n )}\n {options.infinite && (\n <>\n <File.Import name={['useInfiniteQuery']} path={importPath} />\n <File.Import name={['QueryKey', 'InfiniteQueryObserverOptions', 'UseInfiniteQueryResult']} path={importPath} isTypeOnly />\n <InfiniteQuery\n name={query.name}\n queryOptionsName={queryOptions.name}\n typeSchemas={type.schemas}\n paramsCasing={options.paramsCasing}\n paramsType={options.paramsType}\n pathParamsType={options.pathParamsType}\n operation={operation}\n dataReturnType={options.client.dataReturnType}\n queryKeyName={queryKey.name}\n queryKeyTypeName={queryKey.typeName}\n />\n </>\n )}\n </File>\n )\n },\n})\n","import { pluginClientName } from '@kubb/plugin-client'\nimport { Client } from '@kubb/plugin-client/components'\nimport { createReactGenerator } from '@kubb/plugin-oas'\nimport { useOperationManager } from '@kubb/plugin-oas/hooks'\nimport { pluginTsName } from '@kubb/plugin-ts'\nimport { pluginZodName } from '@kubb/plugin-zod'\nimport { File, useApp } from '@kubb/react'\nimport { difference } from 'remeda'\nimport { QueryKey, QueryOptions, SuspenseQuery } from '../components'\nimport type { PluginReactQuery } from '../types'\n\nexport const suspenseQueryGenerator = createReactGenerator<PluginReactQuery>({\n name: 'react-suspense-query',\n Operation({ options, operation }) {\n const {\n plugin: {\n options: { output },\n },\n } = useApp<PluginReactQuery>()\n const { getSchemas, getName, getFile } = useOperationManager()\n\n const isQuery = typeof options.query === 'boolean' ? true : options.query?.methods.some((method) => operation.method === method)\n const isMutation = difference(options.mutation ? options.mutation.methods : [], options.query ? options.query.methods : []).some(\n (method) => operation.method === method,\n )\n\n const isSuspense = !!options.suspense\n\n const importPath = options.query ? options.query.importPath : '@tanstack/react-query'\n\n const query = {\n name: getName(operation, { type: 'function', prefix: 'use', suffix: 'suspense' }),\n typeName: getName(operation, { type: 'type' }),\n file: getFile(operation, { prefix: 'use', suffix: 'suspense' }),\n }\n\n const client = {\n name: getName(operation, { type: 'function' }),\n }\n\n const queryOptions = {\n name: getName(operation, { type: 'function', suffix: 'SuspenseQueryOptions' }),\n }\n\n const queryKey = {\n name: getName(operation, { type: 'const', suffix: 'SuspenseQueryKey' }),\n typeName: getName(operation, { type: 'type', suffix: 'SuspenseQueryKey' }),\n }\n\n const type = {\n file: getFile(operation, { pluginKey: [pluginTsName] }),\n //todo remove type?\n schemas: getSchemas(operation, { pluginKey: [pluginTsName], type: 'type' }),\n }\n\n const zod = {\n file: getFile(operation, { pluginKey: [pluginZodName] }),\n schemas: getSchemas(operation, { pluginKey: [pluginZodName], type: 'function' }),\n }\n\n if (!isQuery || isMutation || !isSuspense) {\n return null\n }\n\n return (\n <File baseName={query.file.baseName} path={query.file.path} meta={query.file.meta} banner={output?.banner} footer={output?.footer}>\n {options.parser === 'zod' && <File.Import name={[zod.schemas.response.name]} root={query.file.path} path={zod.file.path} />}\n <File.Import name={'client'} path={options.client.importPath} />\n <File.Import name={['RequestConfig']} path={options.client.importPath} isTypeOnly />\n {options.client.dataReturnType === 'full' && <File.Import name={['ResponseConfig']} path={options.client.importPath} isTypeOnly />}\n <File.Import\n name={[\n type.schemas.request?.name,\n type.schemas.response.name,\n type.schemas.pathParams?.name,\n type.schemas.queryParams?.name,\n type.schemas.headerParams?.name,\n ...(type.schemas.statusCodes?.map((item) => item.name) || []),\n ].filter(Boolean)}\n root={query.file.path}\n path={type.file.path}\n isTypeOnly\n />\n <QueryKey\n name={queryKey.name}\n typeName={queryKey.typeName}\n operation={operation}\n paramsCasing={options.paramsCasing}\n pathParamsType={options.pathParamsType}\n typeSchemas={type.schemas}\n transformer={options.queryKey}\n />\n\n <Client\n name={client.name}\n isExportable={false}\n isIndexable={false}\n baseURL={options.client.baseURL}\n operation={operation}\n typeSchemas={type.schemas}\n zodSchemas={zod.schemas}\n dataReturnType={options.client.dataReturnType}\n paramsCasing={options.paramsCasing}\n paramsType={options.paramsType}\n pathParamsType={options.pathParamsType}\n parser={options.parser}\n />\n <File.Import name={['queryOptions']} path={importPath} />\n <QueryOptions\n name={queryOptions.name}\n clientName={client.name}\n queryKeyName={queryKey.name}\n typeSchemas={type.schemas}\n paramsCasing={options.paramsCasing}\n paramsType={options.paramsType}\n pathParamsType={options.pathParamsType}\n />\n {options.suspense && (\n <>\n <File.Import name={['useSuspenseQuery']} path={importPath} />\n <File.Import name={['QueryKey', 'UseSuspenseQueryOptions', 'UseSuspenseQueryResult']} path={importPath} isTypeOnly />\n <SuspenseQuery\n name={query.name}\n queryOptionsName={queryOptions.name}\n typeSchemas={type.schemas}\n paramsType={options.paramsType}\n paramsCasing={options.paramsCasing}\n pathParamsType={options.pathParamsType}\n operation={operation}\n dataReturnType={options.client.dataReturnType}\n queryKeyName={queryKey.name}\n queryKeyTypeName={queryKey.typeName}\n />\n </>\n )}\n </File>\n )\n },\n})\n"]}
|
|
@@ -7,13 +7,13 @@ var utils$1 = require('@kubb/plugin-oas/utils');
|
|
|
7
7
|
var jsxRuntime = require('@kubb/react/jsx-runtime');
|
|
8
8
|
|
|
9
9
|
// src/components/Mutation.tsx
|
|
10
|
-
function getParams({ paramsType, pathParamsType, typeSchemas }) {
|
|
10
|
+
function getParams({ paramsType, paramsCasing, pathParamsType, typeSchemas }) {
|
|
11
11
|
if (paramsType === "object") {
|
|
12
12
|
return react.FunctionParams.factory({
|
|
13
13
|
data: {
|
|
14
14
|
mode: "object",
|
|
15
15
|
children: {
|
|
16
|
-
...utils$1.getPathParams(typeSchemas.pathParams, { typed: true }),
|
|
16
|
+
...utils$1.getPathParams(typeSchemas.pathParams, { typed: true, casing: paramsCasing }),
|
|
17
17
|
data: typeSchemas.request?.name ? {
|
|
18
18
|
type: typeSchemas.request?.name,
|
|
19
19
|
optional: oas.isOptional(typeSchemas.request?.schema)
|
|
@@ -37,7 +37,7 @@ function getParams({ paramsType, pathParamsType, typeSchemas }) {
|
|
|
37
37
|
return react.FunctionParams.factory({
|
|
38
38
|
pathParams: typeSchemas.pathParams?.name ? {
|
|
39
39
|
mode: pathParamsType === "object" ? "object" : "inlineSpread",
|
|
40
|
-
children: utils$1.getPathParams(typeSchemas.pathParams, { typed: true }),
|
|
40
|
+
children: utils$1.getPathParams(typeSchemas.pathParams, { typed: true, casing: paramsCasing }),
|
|
41
41
|
optional: oas.isOptional(typeSchemas.pathParams?.schema)
|
|
42
42
|
} : void 0,
|
|
43
43
|
data: typeSchemas.request?.name ? {
|
|
@@ -68,10 +68,11 @@ function Client({
|
|
|
68
68
|
parser,
|
|
69
69
|
zodSchemas,
|
|
70
70
|
paramsType,
|
|
71
|
+
paramsCasing,
|
|
71
72
|
pathParamsType,
|
|
72
73
|
operation
|
|
73
74
|
}) {
|
|
74
|
-
const path = new utils.URLPath(operation.path);
|
|
75
|
+
const path = new utils.URLPath(operation.path, { casing: paramsCasing });
|
|
75
76
|
const contentType = operation.getContentType();
|
|
76
77
|
const isFormData = contentType === "multipart/form-data";
|
|
77
78
|
const headers = [
|
|
@@ -83,7 +84,7 @@ function Client({
|
|
|
83
84
|
typeSchemas.errors?.map((item) => item.name).join(" | ") || "Error",
|
|
84
85
|
typeSchemas.request?.name || "unknown"
|
|
85
86
|
].filter(Boolean);
|
|
86
|
-
const params = getParams({ paramsType, pathParamsType, typeSchemas });
|
|
87
|
+
const params = getParams({ paramsType, paramsCasing, pathParamsType, typeSchemas });
|
|
87
88
|
const clientParams = react.FunctionParams.factory({
|
|
88
89
|
config: {
|
|
89
90
|
mode: "object",
|
|
@@ -147,13 +148,13 @@ Client.getParams = getParams;
|
|
|
147
148
|
function getParams2({}) {
|
|
148
149
|
return react.FunctionParams.factory({});
|
|
149
150
|
}
|
|
150
|
-
var getTransformer = ({ operation }) => {
|
|
151
|
-
const path = new utils.URLPath(operation.path);
|
|
151
|
+
var getTransformer = ({ operation, casing }) => {
|
|
152
|
+
const path = new utils.URLPath(operation.path, { casing });
|
|
152
153
|
return [JSON.stringify({ url: path.path })].filter(Boolean);
|
|
153
154
|
};
|
|
154
|
-
function MutationKey({ name, typeSchemas, pathParamsType, operation, typeName, transformer = getTransformer }) {
|
|
155
|
+
function MutationKey({ name, typeSchemas, pathParamsType, paramsCasing, operation, typeName, transformer = getTransformer }) {
|
|
155
156
|
const params = getParams2({ pathParamsType, typeSchemas });
|
|
156
|
-
const keys = transformer({ operation, schemas: typeSchemas });
|
|
157
|
+
const keys = transformer({ operation, schemas: typeSchemas, casing: paramsCasing });
|
|
157
158
|
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
158
159
|
/* @__PURE__ */ jsxRuntime.jsx(react.File.Source, { name, isExportable: true, isIndexable: true, children: /* @__PURE__ */ jsxRuntime.jsx(react.Function.Arrow, { name, export: true, params: params.toConstructor(), singleLine: true, children: `[${keys.join(", ")}] as const` }) }),
|
|
159
160
|
/* @__PURE__ */ jsxRuntime.jsx(react.File.Source, { name: typeName, isExportable: true, isIndexable: true, isTypeOnly: true, children: /* @__PURE__ */ jsxRuntime.jsx(react.Type, { name: typeName, export: true, children: `ReturnType<typeof ${name}>` }) })
|
|
@@ -161,10 +162,10 @@ function MutationKey({ name, typeSchemas, pathParamsType, operation, typeName, t
|
|
|
161
162
|
}
|
|
162
163
|
MutationKey.getParams = getParams2;
|
|
163
164
|
MutationKey.getTransformer = getTransformer;
|
|
164
|
-
function getParams3({ dataReturnType, typeSchemas }) {
|
|
165
|
+
function getParams3({ paramsCasing, dataReturnType, typeSchemas }) {
|
|
165
166
|
const TData = dataReturnType === "data" ? typeSchemas.response.name : `ResponseConfig<${typeSchemas.response.name}>`;
|
|
166
167
|
const mutationParams = react.FunctionParams.factory({
|
|
167
|
-
...utils$1.getPathParams(typeSchemas.pathParams, { typed: true }),
|
|
168
|
+
...utils$1.getPathParams(typeSchemas.pathParams, { typed: true, casing: paramsCasing }),
|
|
168
169
|
data: typeSchemas.request?.name ? {
|
|
169
170
|
type: typeSchemas.request?.name,
|
|
170
171
|
optional: oas.isOptional(typeSchemas.request?.schema)
|
|
@@ -192,23 +193,35 @@ function getParams3({ dataReturnType, typeSchemas }) {
|
|
|
192
193
|
}
|
|
193
194
|
});
|
|
194
195
|
}
|
|
195
|
-
function Mutation({
|
|
196
|
+
function Mutation({
|
|
197
|
+
name,
|
|
198
|
+
clientName,
|
|
199
|
+
paramsCasing,
|
|
200
|
+
paramsType,
|
|
201
|
+
pathParamsType,
|
|
202
|
+
dataReturnType,
|
|
203
|
+
typeSchemas,
|
|
204
|
+
operation,
|
|
205
|
+
mutationKeyName
|
|
206
|
+
}) {
|
|
196
207
|
const mutationKeyParams = MutationKey.getParams({
|
|
197
208
|
pathParamsType,
|
|
198
209
|
typeSchemas
|
|
199
210
|
});
|
|
200
211
|
const params = getParams3({
|
|
212
|
+
paramsCasing,
|
|
201
213
|
pathParamsType,
|
|
202
214
|
dataReturnType,
|
|
203
215
|
typeSchemas
|
|
204
216
|
});
|
|
205
217
|
const clientParams = Client.getParams({
|
|
218
|
+
paramsCasing,
|
|
206
219
|
paramsType,
|
|
207
220
|
typeSchemas,
|
|
208
221
|
pathParamsType
|
|
209
222
|
});
|
|
210
223
|
const mutationParams = react.FunctionParams.factory({
|
|
211
|
-
...utils$1.getPathParams(typeSchemas.pathParams, { typed: true }),
|
|
224
|
+
...utils$1.getPathParams(typeSchemas.pathParams, { typed: true, casing: paramsCasing }),
|
|
212
225
|
data: typeSchemas.request?.name ? {
|
|
213
226
|
type: typeSchemas.request?.name,
|
|
214
227
|
optional: oas.isOptional(typeSchemas.request?.schema)
|
|
@@ -265,11 +278,11 @@ function Mutation({ name, clientName, paramsType, pathParamsType, dataReturnType
|
|
|
265
278
|
}
|
|
266
279
|
) });
|
|
267
280
|
}
|
|
268
|
-
function getParams4({ pathParamsType, typeSchemas }) {
|
|
281
|
+
function getParams4({ pathParamsType, paramsCasing, typeSchemas }) {
|
|
269
282
|
return react.FunctionParams.factory({
|
|
270
283
|
pathParams: {
|
|
271
284
|
mode: pathParamsType === "object" ? "object" : "inlineSpread",
|
|
272
|
-
children: utils$1.getPathParams(typeSchemas.pathParams, { typed: true })
|
|
285
|
+
children: utils$1.getPathParams(typeSchemas.pathParams, { typed: true, casing: paramsCasing })
|
|
273
286
|
},
|
|
274
287
|
data: typeSchemas.request?.name ? {
|
|
275
288
|
type: typeSchemas.request?.name,
|
|
@@ -281,8 +294,8 @@ function getParams4({ pathParamsType, typeSchemas }) {
|
|
|
281
294
|
} : void 0
|
|
282
295
|
});
|
|
283
296
|
}
|
|
284
|
-
var getTransformer2 = ({ operation, schemas }) => {
|
|
285
|
-
const path = new utils.URLPath(operation.path);
|
|
297
|
+
var getTransformer2 = ({ operation, schemas, casing }) => {
|
|
298
|
+
const path = new utils.URLPath(operation.path, { casing });
|
|
286
299
|
const keys = [
|
|
287
300
|
path.toObject({
|
|
288
301
|
type: "path",
|
|
@@ -293,11 +306,12 @@ var getTransformer2 = ({ operation, schemas }) => {
|
|
|
293
306
|
].filter(Boolean);
|
|
294
307
|
return keys;
|
|
295
308
|
};
|
|
296
|
-
function QueryKey({ name, typeSchemas, pathParamsType, operation, typeName, transformer = getTransformer2 }) {
|
|
297
|
-
const params = getParams4({ pathParamsType, typeSchemas });
|
|
309
|
+
function QueryKey({ name, typeSchemas, paramsCasing, pathParamsType, operation, typeName, transformer = getTransformer2 }) {
|
|
310
|
+
const params = getParams4({ pathParamsType, typeSchemas, paramsCasing });
|
|
298
311
|
const keys = transformer({
|
|
299
312
|
operation,
|
|
300
|
-
schemas: typeSchemas
|
|
313
|
+
schemas: typeSchemas,
|
|
314
|
+
casing: paramsCasing
|
|
301
315
|
});
|
|
302
316
|
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
303
317
|
/* @__PURE__ */ jsxRuntime.jsx(react.File.Source, { name, isExportable: true, isIndexable: true, children: /* @__PURE__ */ jsxRuntime.jsx(react.Function.Arrow, { name, export: true, params: params.toConstructor(), singleLine: true, children: `[${keys.join(", ")}] as const` }) }),
|
|
@@ -306,13 +320,13 @@ function QueryKey({ name, typeSchemas, pathParamsType, operation, typeName, tran
|
|
|
306
320
|
}
|
|
307
321
|
QueryKey.getParams = getParams4;
|
|
308
322
|
QueryKey.getTransformer = getTransformer2;
|
|
309
|
-
function getParams5({ paramsType, pathParamsType, typeSchemas }) {
|
|
323
|
+
function getParams5({ paramsType, paramsCasing, pathParamsType, typeSchemas }) {
|
|
310
324
|
if (paramsType === "object") {
|
|
311
325
|
return react.FunctionParams.factory({
|
|
312
326
|
data: {
|
|
313
327
|
mode: "object",
|
|
314
328
|
children: {
|
|
315
|
-
...utils$1.getPathParams(typeSchemas.pathParams, { typed: true }),
|
|
329
|
+
...utils$1.getPathParams(typeSchemas.pathParams, { typed: true, casing: paramsCasing }),
|
|
316
330
|
data: typeSchemas.request?.name ? {
|
|
317
331
|
type: typeSchemas.request?.name,
|
|
318
332
|
optional: oas.isOptional(typeSchemas.request?.schema)
|
|
@@ -336,7 +350,7 @@ function getParams5({ paramsType, pathParamsType, typeSchemas }) {
|
|
|
336
350
|
return react.FunctionParams.factory({
|
|
337
351
|
pathParams: typeSchemas.pathParams?.name ? {
|
|
338
352
|
mode: pathParamsType === "object" ? "object" : "inlineSpread",
|
|
339
|
-
children: utils$1.getPathParams(typeSchemas.pathParams, { typed: true }),
|
|
353
|
+
children: utils$1.getPathParams(typeSchemas.pathParams, { typed: true, casing: paramsCasing }),
|
|
340
354
|
optional: oas.isOptional(typeSchemas.pathParams?.schema)
|
|
341
355
|
} : void 0,
|
|
342
356
|
data: typeSchemas.request?.name ? {
|
|
@@ -357,16 +371,18 @@ function getParams5({ paramsType, pathParamsType, typeSchemas }) {
|
|
|
357
371
|
}
|
|
358
372
|
});
|
|
359
373
|
}
|
|
360
|
-
function QueryOptions({ name, clientName, typeSchemas, paramsType, pathParamsType, queryKeyName }) {
|
|
361
|
-
const params = getParams5({ paramsType, pathParamsType, typeSchemas });
|
|
374
|
+
function QueryOptions({ name, clientName, typeSchemas, paramsCasing, paramsType, pathParamsType, queryKeyName }) {
|
|
375
|
+
const params = getParams5({ paramsType, paramsCasing, pathParamsType, typeSchemas });
|
|
362
376
|
const clientParams = Client.getParams({
|
|
363
377
|
typeSchemas,
|
|
378
|
+
paramsCasing,
|
|
364
379
|
paramsType,
|
|
365
380
|
pathParamsType
|
|
366
381
|
});
|
|
367
382
|
const queryKeyParams = QueryKey.getParams({
|
|
368
383
|
pathParamsType,
|
|
369
|
-
typeSchemas
|
|
384
|
+
typeSchemas,
|
|
385
|
+
paramsCasing
|
|
370
386
|
});
|
|
371
387
|
const enabled = Object.entries(queryKeyParams.flatParams).map(([key, item]) => item && !item.optional ? key : void 0).filter(Boolean).join("&& ");
|
|
372
388
|
const enabledText = enabled ? `enabled: !!(${enabled}),` : "";
|
|
@@ -383,14 +399,14 @@ function QueryOptions({ name, clientName, typeSchemas, paramsType, pathParamsTyp
|
|
|
383
399
|
` }) });
|
|
384
400
|
}
|
|
385
401
|
QueryOptions.getParams = getParams5;
|
|
386
|
-
function getParams6({ paramsType, pathParamsType, dataReturnType, typeSchemas }) {
|
|
402
|
+
function getParams6({ paramsType, paramsCasing, pathParamsType, dataReturnType, typeSchemas }) {
|
|
387
403
|
const TData = dataReturnType === "data" ? typeSchemas.response.name : `ResponseConfig<${typeSchemas.response.name}>`;
|
|
388
404
|
if (paramsType === "object") {
|
|
389
405
|
return react.FunctionParams.factory({
|
|
390
406
|
data: {
|
|
391
407
|
mode: "object",
|
|
392
408
|
children: {
|
|
393
|
-
...utils$1.getPathParams(typeSchemas.pathParams, { typed: true }),
|
|
409
|
+
...utils$1.getPathParams(typeSchemas.pathParams, { typed: true, casing: paramsCasing }),
|
|
394
410
|
data: typeSchemas.request?.name ? {
|
|
395
411
|
type: typeSchemas.request?.name,
|
|
396
412
|
optional: oas.isOptional(typeSchemas.request?.schema)
|
|
@@ -419,7 +435,7 @@ function getParams6({ paramsType, pathParamsType, dataReturnType, typeSchemas })
|
|
|
419
435
|
return react.FunctionParams.factory({
|
|
420
436
|
pathParams: typeSchemas.pathParams?.name ? {
|
|
421
437
|
mode: pathParamsType === "object" ? "object" : "inlineSpread",
|
|
422
|
-
children: utils$1.getPathParams(typeSchemas.pathParams, { typed: true }),
|
|
438
|
+
children: utils$1.getPathParams(typeSchemas.pathParams, { typed: true, casing: paramsCasing }),
|
|
423
439
|
optional: oas.isOptional(typeSchemas.pathParams?.schema)
|
|
424
440
|
} : void 0,
|
|
425
441
|
data: typeSchemas.request?.name ? {
|
|
@@ -451,6 +467,7 @@ function Query({
|
|
|
451
467
|
queryOptionsName,
|
|
452
468
|
queryKeyName,
|
|
453
469
|
paramsType,
|
|
470
|
+
paramsCasing,
|
|
454
471
|
pathParamsType,
|
|
455
472
|
dataReturnType,
|
|
456
473
|
typeSchemas,
|
|
@@ -461,14 +478,17 @@ function Query({
|
|
|
461
478
|
const generics = [`TData = ${TData}`, `TQueryData = ${TData}`, `TQueryKey extends QueryKey = ${queryKeyTypeName}`];
|
|
462
479
|
const queryKeyParams = QueryKey.getParams({
|
|
463
480
|
pathParamsType,
|
|
464
|
-
typeSchemas
|
|
481
|
+
typeSchemas,
|
|
482
|
+
paramsCasing
|
|
465
483
|
});
|
|
466
484
|
const queryOptionsParams = QueryOptions.getParams({
|
|
467
485
|
paramsType,
|
|
468
486
|
pathParamsType,
|
|
469
|
-
typeSchemas
|
|
487
|
+
typeSchemas,
|
|
488
|
+
paramsCasing
|
|
470
489
|
});
|
|
471
490
|
const params = getParams6({
|
|
491
|
+
paramsCasing,
|
|
472
492
|
paramsType,
|
|
473
493
|
pathParamsType,
|
|
474
494
|
dataReturnType,
|
|
@@ -503,13 +523,13 @@ function Query({
|
|
|
503
523
|
) });
|
|
504
524
|
}
|
|
505
525
|
Query.getParams = getParams6;
|
|
506
|
-
function getParams7({ paramsType, pathParamsType, typeSchemas }) {
|
|
526
|
+
function getParams7({ paramsType, paramsCasing, pathParamsType, typeSchemas }) {
|
|
507
527
|
if (paramsType === "object") {
|
|
508
528
|
return react.FunctionParams.factory({
|
|
509
529
|
data: {
|
|
510
530
|
mode: "object",
|
|
511
531
|
children: {
|
|
512
|
-
...utils$1.getPathParams(typeSchemas.pathParams, { typed: true }),
|
|
532
|
+
...utils$1.getPathParams(typeSchemas.pathParams, { typed: true, casing: paramsCasing }),
|
|
513
533
|
data: typeSchemas.request?.name ? {
|
|
514
534
|
type: typeSchemas.request?.name,
|
|
515
535
|
optional: oas.isOptional(typeSchemas.request?.schema)
|
|
@@ -533,7 +553,7 @@ function getParams7({ paramsType, pathParamsType, typeSchemas }) {
|
|
|
533
553
|
return react.FunctionParams.factory({
|
|
534
554
|
pathParams: typeSchemas.pathParams?.name ? {
|
|
535
555
|
mode: pathParamsType === "object" ? "object" : "inlineSpread",
|
|
536
|
-
children: utils$1.getPathParams(typeSchemas.pathParams, { typed: true }),
|
|
556
|
+
children: utils$1.getPathParams(typeSchemas.pathParams, { typed: true, casing: paramsCasing }),
|
|
537
557
|
optional: oas.isOptional(typeSchemas.pathParams?.schema)
|
|
538
558
|
} : void 0,
|
|
539
559
|
data: typeSchemas.request?.name ? {
|
|
@@ -560,21 +580,24 @@ function InfiniteQueryOptions({
|
|
|
560
580
|
initialPageParam,
|
|
561
581
|
cursorParam,
|
|
562
582
|
typeSchemas,
|
|
583
|
+
paramsCasing,
|
|
563
584
|
paramsType,
|
|
564
585
|
dataReturnType,
|
|
565
586
|
pathParamsType,
|
|
566
587
|
queryParam,
|
|
567
588
|
queryKeyName
|
|
568
589
|
}) {
|
|
569
|
-
const params = getParams7({ paramsType, pathParamsType, typeSchemas });
|
|
590
|
+
const params = getParams7({ paramsType, paramsCasing, pathParamsType, typeSchemas });
|
|
570
591
|
const clientParams = Client.getParams({
|
|
592
|
+
paramsCasing,
|
|
571
593
|
typeSchemas,
|
|
572
594
|
paramsType,
|
|
573
595
|
pathParamsType
|
|
574
596
|
});
|
|
575
597
|
const queryKeyParams = QueryKey.getParams({
|
|
576
598
|
pathParamsType,
|
|
577
|
-
typeSchemas
|
|
599
|
+
typeSchemas,
|
|
600
|
+
paramsCasing
|
|
578
601
|
});
|
|
579
602
|
const queryOptions = [
|
|
580
603
|
`initialPageParam: ${typeof initialPageParam === "string" ? JSON.stringify(initialPageParam) : initialPageParam}`,
|
|
@@ -619,14 +642,14 @@ function InfiniteQueryOptions({
|
|
|
619
642
|
] }) });
|
|
620
643
|
}
|
|
621
644
|
InfiniteQueryOptions.getParams = getParams7;
|
|
622
|
-
function getParams8({ paramsType, pathParamsType, dataReturnType, typeSchemas }) {
|
|
645
|
+
function getParams8({ paramsType, paramsCasing, pathParamsType, dataReturnType, typeSchemas }) {
|
|
623
646
|
const TData = dataReturnType === "data" ? typeSchemas.response.name : `ResponseConfig<${typeSchemas.response.name}>`;
|
|
624
647
|
if (paramsType === "object") {
|
|
625
648
|
return react.FunctionParams.factory({
|
|
626
649
|
data: {
|
|
627
650
|
mode: "object",
|
|
628
651
|
children: {
|
|
629
|
-
...utils$1.getPathParams(typeSchemas.pathParams, { typed: true }),
|
|
652
|
+
...utils$1.getPathParams(typeSchemas.pathParams, { typed: true, casing: paramsCasing }),
|
|
630
653
|
data: typeSchemas.request?.name ? {
|
|
631
654
|
type: typeSchemas.request?.name,
|
|
632
655
|
optional: oas.isOptional(typeSchemas.request?.schema)
|
|
@@ -655,7 +678,7 @@ function getParams8({ paramsType, pathParamsType, dataReturnType, typeSchemas })
|
|
|
655
678
|
return react.FunctionParams.factory({
|
|
656
679
|
pathParams: typeSchemas.pathParams?.name ? {
|
|
657
680
|
mode: pathParamsType === "object" ? "object" : "inlineSpread",
|
|
658
|
-
children: utils$1.getPathParams(typeSchemas.pathParams, { typed: true }),
|
|
681
|
+
children: utils$1.getPathParams(typeSchemas.pathParams, { typed: true, casing: paramsCasing }),
|
|
659
682
|
optional: oas.isOptional(typeSchemas.pathParams?.schema)
|
|
660
683
|
} : void 0,
|
|
661
684
|
data: typeSchemas.request?.name ? {
|
|
@@ -687,6 +710,7 @@ function InfiniteQuery({
|
|
|
687
710
|
queryOptionsName,
|
|
688
711
|
queryKeyName,
|
|
689
712
|
paramsType,
|
|
713
|
+
paramsCasing,
|
|
690
714
|
pathParamsType,
|
|
691
715
|
dataReturnType,
|
|
692
716
|
typeSchemas,
|
|
@@ -697,14 +721,17 @@ function InfiniteQuery({
|
|
|
697
721
|
const generics = [`TData = InfiniteData<${TData}>`, `TQueryData = ${TData}`, `TQueryKey extends QueryKey = ${queryKeyTypeName}`];
|
|
698
722
|
const queryKeyParams = QueryKey.getParams({
|
|
699
723
|
pathParamsType,
|
|
700
|
-
typeSchemas
|
|
724
|
+
typeSchemas,
|
|
725
|
+
paramsCasing
|
|
701
726
|
});
|
|
702
727
|
const queryOptionsParams = QueryOptions.getParams({
|
|
703
728
|
paramsType,
|
|
704
729
|
pathParamsType,
|
|
705
|
-
typeSchemas
|
|
730
|
+
typeSchemas,
|
|
731
|
+
paramsCasing
|
|
706
732
|
});
|
|
707
733
|
const params = getParams8({
|
|
734
|
+
paramsCasing,
|
|
708
735
|
paramsType,
|
|
709
736
|
pathParamsType,
|
|
710
737
|
dataReturnType,
|
|
@@ -739,14 +766,14 @@ function InfiniteQuery({
|
|
|
739
766
|
) });
|
|
740
767
|
}
|
|
741
768
|
InfiniteQuery.getParams = getParams8;
|
|
742
|
-
function getParams9({ paramsType, pathParamsType, dataReturnType, typeSchemas }) {
|
|
769
|
+
function getParams9({ paramsType, paramsCasing, pathParamsType, dataReturnType, typeSchemas }) {
|
|
743
770
|
const TData = dataReturnType === "data" ? typeSchemas.response.name : `ResponseConfig<${typeSchemas.response.name}>`;
|
|
744
771
|
if (paramsType === "object") {
|
|
745
772
|
return react.FunctionParams.factory({
|
|
746
773
|
data: {
|
|
747
774
|
mode: "object",
|
|
748
775
|
children: {
|
|
749
|
-
...utils$1.getPathParams(typeSchemas.pathParams, { typed: true }),
|
|
776
|
+
...utils$1.getPathParams(typeSchemas.pathParams, { typed: true, casing: paramsCasing }),
|
|
750
777
|
data: typeSchemas.request?.name ? {
|
|
751
778
|
type: typeSchemas.request?.name,
|
|
752
779
|
optional: oas.isOptional(typeSchemas.request?.schema)
|
|
@@ -775,7 +802,7 @@ function getParams9({ paramsType, pathParamsType, dataReturnType, typeSchemas })
|
|
|
775
802
|
return react.FunctionParams.factory({
|
|
776
803
|
pathParams: typeSchemas.pathParams?.name ? {
|
|
777
804
|
mode: pathParamsType === "object" ? "object" : "inlineSpread",
|
|
778
|
-
children: utils$1.getPathParams(typeSchemas.pathParams, { typed: true }),
|
|
805
|
+
children: utils$1.getPathParams(typeSchemas.pathParams, { typed: true, casing: paramsCasing }),
|
|
779
806
|
optional: oas.isOptional(typeSchemas.pathParams?.schema)
|
|
780
807
|
} : void 0,
|
|
781
808
|
data: typeSchemas.request?.name ? {
|
|
@@ -807,6 +834,7 @@ function SuspenseQuery({
|
|
|
807
834
|
queryOptionsName,
|
|
808
835
|
queryKeyName,
|
|
809
836
|
paramsType,
|
|
837
|
+
paramsCasing,
|
|
810
838
|
pathParamsType,
|
|
811
839
|
dataReturnType,
|
|
812
840
|
typeSchemas,
|
|
@@ -817,14 +845,17 @@ function SuspenseQuery({
|
|
|
817
845
|
const generics = [`TData = ${TData}`, `TQueryData = ${TData}`, `TQueryKey extends QueryKey = ${queryKeyTypeName}`];
|
|
818
846
|
const queryKeyParams = QueryKey.getParams({
|
|
819
847
|
pathParamsType,
|
|
820
|
-
typeSchemas
|
|
848
|
+
typeSchemas,
|
|
849
|
+
paramsCasing
|
|
821
850
|
});
|
|
822
851
|
const queryOptionsParams = QueryOptions.getParams({
|
|
852
|
+
paramsCasing,
|
|
823
853
|
paramsType,
|
|
824
854
|
pathParamsType,
|
|
825
855
|
typeSchemas
|
|
826
856
|
});
|
|
827
857
|
const params = getParams9({
|
|
858
|
+
paramsCasing,
|
|
828
859
|
paramsType,
|
|
829
860
|
pathParamsType,
|
|
830
861
|
dataReturnType,
|
|
@@ -869,5 +900,5 @@ exports.Query = Query;
|
|
|
869
900
|
exports.QueryKey = QueryKey;
|
|
870
901
|
exports.QueryOptions = QueryOptions;
|
|
871
902
|
exports.SuspenseQuery = SuspenseQuery;
|
|
872
|
-
//# sourceMappingURL=chunk-
|
|
873
|
-
//# sourceMappingURL=chunk-
|
|
903
|
+
//# sourceMappingURL=chunk-EZXV6KB3.cjs.map
|
|
904
|
+
//# sourceMappingURL=chunk-EZXV6KB3.cjs.map
|